diff --git a/CHANGELOG.md b/CHANGELOG.md index edc8b30d8..cf514971b 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -35,6 +35,7 @@ All notable changes to this project will be documented in this file. - Exporting DefineJPEG3/4 with alpha channel to PNG produced JPEG instead - AS3 package level const with function value - separate P-code for trait and method - Slot/const trait proper p-code indentation +- [#1858] Adding same ExtGState multiple times ### Changed - Warning before switching deobfuscation is now optional diff --git a/lib/gnujpdf.jar b/lib/gnujpdf.jar index 4d54e5627..a777497df 100644 Binary files a/lib/gnujpdf.jar and b/lib/gnujpdf.jar differ diff --git a/libsrc/gnujpdf/src/gnu/jpdf/PDFPage.java b/libsrc/gnujpdf/src/gnu/jpdf/PDFPage.java index c5f1b17ac..b3bd7e67f 100644 --- a/libsrc/gnujpdf/src/gnu/jpdf/PDFPage.java +++ b/libsrc/gnujpdf/src/gnu/jpdf/PDFPage.java @@ -454,7 +454,9 @@ public class PDFPage extends PDFObject implements Serializable { } public void addExtGStateResource(String resource) { - extGStateResources.add(resource); + if (!extGStateResources.contains(resource)) { + extGStateResources.add(resource); + } } /**