8144991: AIOOB Exception in AutoImageWriterTest with TIFF writer
Summary: In TIFFImageWriter call reset() in setOuput() when output != null.
Reviewed-by: prr
--- a/jdk/src/java.desktop/share/classes/com/sun/imageio/plugins/tiff/TIFFImageWriter.java Mon Jan 04 17:05:04 2016 -0800
+++ b/jdk/src/java.desktop/share/classes/com/sun/imageio/plugins/tiff/TIFFImageWriter.java Mon Jan 04 17:07:23 2016 -0800
@@ -266,6 +266,8 @@
super.setOutput(output);
if (output != null) {
+ reset();
+
if (!(output instanceof ImageOutputStream)) {
throw new IllegalArgumentException
("output not an ImageOutputStream!");