Commit 8dec9ce2 authored by Volker Krause's avatar Volker Krause
Browse files

Fix filter pattern matching against null bytes in binary content

parent e69593ec
......@@ -26,7 +26,8 @@ ExtractorDocumentNode BinaryDocumentProcessor::createNodeFromData(const QByteArr
bool BinaryDocumentProcessor::matches(const ExtractorFilter &filter, const ExtractorDocumentNode &node) const
{
return filter.matches(QString::fromLatin1(node.content<QByteArray>()));
const auto b = node.content<QByteArray>();
return filter.matches(QString::fromLatin1(b.constData(), b.size()));
}
QJSValue BinaryDocumentProcessor::contentToScriptValue(const ExtractorDocumentNode &node, QJSEngine *engine) const
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment