-
Bug
-
Resolution: Unresolved
-
P4
-
5.0, 6, 7, 8, 9, 10, 11, 12, 13, 14
We have a 2D negative test written by Praveen M. some time in 2003. The test does invoke ImageReadParam.setDestination() passing there various incompatible formats. The method specification claims there should be IIOException on an attempt to read.
It never did work that way but with time, the variety of different exceptions thrown became truly entertaining. It's
java.lang.IndexOutOfBoundsException: off < 0 || len < 0 || off + len > b.length!
java.lang.NullPointerException
java.lang.ClassCastException: java.awt.image.SinglePixelPackedSampleModel (in module: java.desktop) cannot be cast to java.awt.image.MultiPixelPackedSampleModel
java.lang.ClassCastException: java.awt.image.PixelInterleavedSampleModel (in module: java.desktop) cannot be cast to java.awt.image.MultiPixelPackedSampleModel
java.lang.IllegalArgumentException: ImageReadParam num source & dest bands differ!
java.lang.ClassCastException: [B (in module: java.base) cannot be cast to [S
java.lang.ArrayIndexOutOfBoundsException: 85
java.lang.ClassCastException: [B (in module: java.base) cannot be cast to [I
It never did work that way but with time, the variety of different exceptions thrown became truly entertaining. It's
java.lang.IndexOutOfBoundsException: off < 0 || len < 0 || off + len > b.length!
java.lang.NullPointerException
java.lang.ClassCastException: java.awt.image.SinglePixelPackedSampleModel (in module: java.desktop) cannot be cast to java.awt.image.MultiPixelPackedSampleModel
java.lang.ClassCastException: java.awt.image.PixelInterleavedSampleModel (in module: java.desktop) cannot be cast to java.awt.image.MultiPixelPackedSampleModel
java.lang.IllegalArgumentException: ImageReadParam num source & dest bands differ!
java.lang.ClassCastException: [B (in module: java.base) cannot be cast to [S
java.lang.ArrayIndexOutOfBoundsException: 85
java.lang.ClassCastException: [B (in module: java.base) cannot be cast to [I
- duplicates
-
JDK-6433172 BMPImageReader fails if the Destination is set
- Closed
-
JDK-8159355 2D_ImageIOTiger/UnsupportedDestinationTest fails as Different Exception is thrown instead of IIOException
- Closed
- relates to
-
JDK-4893377 ImageReader.read does not throw IIOException when destination is incompatible
- Closed