Uploaded image for project: 'Commons Imaging'
  1. Commons Imaging
  2. IMAGING-31

ArrayIndexOutOfBoundsException with GIF

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Major
    • Resolution: Fixed
    • None
    • 1.0-alpha1
    • None
    • None

    Description

      I try to get a BufferedImage:

      import java.io.File;
      import java.awt.image.BufferedImage;
      import org.apache.sanselan.Sanselan;
      public class BufferedImageTest {
      public static void main(String[] args) throws Exception

      { BufferedImage img = Sanselan.getBufferedImage(new File(args[0])); }

      }

      This throw a ArrayIndexOutOfBoundsException if I use a special gif (test.gif is attached)
      This GIF was created by PowerPoint

      Exception in thread "main" java.lang.ArrayIndexOutOfBoundsException: 96000
      at org.apache.sanselan.formats.gif.GifImageParser.getBufferedImage(GifImageParser.java:795)
      at org.apache.sanselan.Sanselan.getBufferedImage(Sanselan.java:1264)
      at org.apache.sanselan.Sanselan.getBufferedImage(Sanselan.java:1231)
      at BufferedImageTest.main(BufferedImageTest.java:6)

      Attachments

        1. test.gif
          27 kB
          Holger Veltrup

        Activity

          People

            Unassigned Unassigned
            veltrup Holger Veltrup
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: