[OpenJDK 2D-Dev] [15] RFR JDK-6532025: GIF reader throws misleading exception with truncated images
Jayathirth D v
JAYATHIRTH.D.V at ORACLE.COM
Thu Mar 5 10:12:31 UTC 2020
Hello All,
Please review the following fix for JDK 15:
Bug : https://bugs.openjdk.java.net/browse/JDK-6532025 <https://bugs.openjdk.java.net/browse/JDK-6532025>
Webrev : http://cr.openjdk.java.net/~jdv/6532025/webrev.00/ <http://cr.openjdk.java.net/~jdv/6532025/webrev.00/>
Root cause : When we have truncated GIF images, stream.read() returns -1 but GIFImageReader doesn’t handle such conditions properly and continues to read input stream data.
Solution : Handle cases where we reach EOF and throw appropriate exception.
Thanks,
Jay
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://mail.openjdk.java.net/pipermail/2d-dev/attachments/20200305/173f72c5/attachment.htm>
More information about the 2d-dev
mailing list