Details
-
Bug
-
Status: Open
-
Major
-
Resolution: Unresolved
-
1.0-alpha3
-
None
Description
The following snipped throws an ArrayIndexOutOfBoundsException:
Imaging.getAllBufferedImages(FileUtils.readFileToByteArray(new File("ArrayIndexOutOfBoundsException.icon")));
Exception in thread "main" java.lang.ArrayIndexOutOfBoundsException: Index 65539 out of bounds for length 65536 at org.apache.commons.imaging.formats.icns.Rle24Compression.decompress(Rle24Compression.java:51) at org.apache.commons.imaging.formats.icns.IcnsDecoder.decodeImageImpl(IcnsDecoder.java:254) at org.apache.commons.imaging.formats.icns.IcnsDecoder.decodeImage(IcnsDecoder.java:241) at org.apache.commons.imaging.formats.icns.IcnsDecoder.decodeAllImages(IcnsDecoder.java:197) at org.apache.commons.imaging.formats.icns.IcnsImageParser.getAllBufferedImages(IcnsImageParser.java:246) at org.apache.commons.imaging.Imaging.getAllBufferedImages(Imaging.java:758) at org.apache.commons.imaging.Imaging.getAllBufferedImages(Imaging.java:741)