mirror of
https://invent.kde.org/graphics/okular
synced 2024-10-02 14:14:10 +00:00
Fix crash on files that have the same signature in more than 1 page
It happens with some official documents where they use the same signature in all pages to make it clear all pages are signed/official BUGS: 426467
This commit is contained in:
parent
f1b29aca4f
commit
9bf171a108
|
@ -790,11 +790,11 @@ void PDFGenerator::loadPages(QVector<Okular::Page *> &pagesVector, int rotation,
|
|||
if (std::find_if(pageFormFields.begin(), pageFormFields.end(), compareSignatureByFullyQualifiedName) != pageFormFields.end()) {
|
||||
delete s;
|
||||
createSignature = false;
|
||||
continue;
|
||||
break;
|
||||
}
|
||||
}
|
||||
// See if the signature is in page 0
|
||||
if (std::find_if(page0FormFields.constBegin(), page0FormFields.constEnd(), compareSignatureByFullyQualifiedName) != page0FormFields.constEnd()) {
|
||||
if (createSignature && std::find_if(page0FormFields.constBegin(), page0FormFields.constEnd(), compareSignatureByFullyQualifiedName) != page0FormFields.constEnd()) {
|
||||
delete s;
|
||||
createSignature = false;
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue