mirror of https://github.com/JakubMelka/PDF4QT.git
Issue #50: Fix of 00007.pdf
This commit is contained in:
parent
37dd55a361
commit
0b47464241
|
@ -523,12 +523,17 @@ QByteArray PDFFlateDecodeFilter::uncompress(const QByteArray& data)
|
|||
|
||||
default:
|
||||
{
|
||||
if (errorMessage.isEmpty())
|
||||
{
|
||||
errorMessage = PDFTranslationContext::tr("zlib code: %1").arg(error);
|
||||
}
|
||||
const bool ignoreError = error == Z_DATA_ERROR && errorMessage == "incorrect data check";
|
||||
|
||||
throw PDFException(PDFTranslationContext::tr("Error decompressing by flate method: %1").arg(errorMessage));
|
||||
if (!ignoreError)
|
||||
{
|
||||
if (errorMessage.isEmpty())
|
||||
{
|
||||
errorMessage = PDFTranslationContext::tr("zlib code: %1").arg(error);
|
||||
}
|
||||
|
||||
throw PDFException(PDFTranslationContext::tr("Error decompressing by flate method: %1").arg(errorMessage));
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue