Import PDML text proto as hexdump if non-text chars
This commit is contained in:
parent
5efffb0c4b
commit
c335f34651
@ -101,6 +101,15 @@ _retry:
|
||||
goto _retry;
|
||||
}
|
||||
|
||||
QByteArray line = QByteArray::fromHex(
|
||||
attributes.value("value").toString().toUtf8());
|
||||
foreach(char c, line) {
|
||||
if (!isprint(c) && !isspace(c)) {
|
||||
contentType_ = kOtherContent;
|
||||
goto _retry;
|
||||
}
|
||||
}
|
||||
|
||||
if (pos < expPos_)
|
||||
break;
|
||||
|
||||
@ -127,9 +136,6 @@ _retry:
|
||||
expPos_ += gap;
|
||||
}
|
||||
|
||||
QByteArray line = QByteArray::fromHex(
|
||||
attributes.value("value").toString().toUtf8());
|
||||
|
||||
if (detectEol_)
|
||||
{
|
||||
if (line.right(2) == "\r\n")
|
||||
|
Loading…
Reference in New Issue
Block a user