mirror of
https://github.com/JakubMelka/PDF4QT.git
synced 2025-06-05 21:59:17 +02:00
Issue #163: Unable to render probably valid PDF
This commit is contained in:
@ -353,10 +353,15 @@ void PDFSecurityHandler::parseDataStandardSecurityHandler(const PDFDictionary* d
|
||||
{
|
||||
result = object.getString();
|
||||
|
||||
if (result.size() != size)
|
||||
if (result.size() < size)
|
||||
{
|
||||
throw PDFException(PDFTranslationContext::tr("Expected %1 characters long string in entry '%2'. Provided length is %3.").arg(size).arg(QString::fromLatin1(key)).arg(result.size()));
|
||||
}
|
||||
|
||||
if (result.size() > size)
|
||||
{
|
||||
result.resize(size);
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
|
Reference in New Issue
Block a user