Uploaded image for project: 'JDK'
  1. JDK
  2. JDK-6275369

PIT:GIFWriter.endWriteSequence() throws a NullPointerException when output is not set

    XMLWordPrintable

Details

    • beta
    • generic
    • generic
    • Verified

    Description

      ImageWriter.endWriteSequence() is supposed to throw an IllegalStateException when output is not set for the writer. But currently this method throws the following NullPointerException:
      java.lang.NullPointerException
      at com.sun.imageio.plugins.gif.GIFImageWriter.writeTrailer(GIFImageWriter.java:1187)
      at com.sun.imageio.plugins.gif.GIFImageWriter.endWriteSequence(GIFImageWriter.java:327)
      at WriterTest.createBufferedImage(WriterTest.java:88)
      at WriterTest.<init>(WriterTest.java:27)
      at WriterTest.main(WriterTest.java:100)

      This is reproducible on all platforms with the current 2D PIT build dated May'23rd.

      I have attached a sample test. Execute the sample test. If you see the above NPE on the console, the bug is reproduced.

      ###@###.### 2005-05-24 18:09:05 GMT

      Attachments

        Issue Links

          Activity

            People

              bae Andrew Brygin
              pmohansunw Praveen Mohan (Inactive)
              Votes:
              0 Vote for this issue
              Watchers:
              0 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved:
                Imported:
                Indexed: