THausherr commented on PR #6: URL: https://github.com/apache/pdfbox-jbig2/pull/6#issuecomment-6654995135
Thank you; here's feedback by copilot: One issue found — medium severity (PatternDictionary.java:130): the cast happens after grayMax + 1 is evaluated as an int, so grayMax == Integer.MAX_VALUE overflows before the multiplication. The guard then passes, and decoding later fails with an unchecked IllegalArgumentException instead of InvalidHeaderValueException. Cast before adding: ((long) grayMax + 1) * hdpWidth. -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected] --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]
