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

Animated GIF eats CPU when not visible

XMLWordPrintable

    • 04
    • x86, sparc
    • solaris_7, windows_nt

        This bug originally reported by ###@###.###.

        The problem occurs when an animated gif is displayed, and then the window displaying it is still disposed. The GIF continues to eat CPU cycles (quite a lot of them actually). Here is a message describing the test case:

        -------------------------------
         the testcase loads(place it in the
        same location as the class file). After starting the testcase you see a
        window with a button labeled "Show Image". Press this button to open a
        JWindow containing a JLabel displaying the animated gif. Note the cpu
        load while the JWindow is open then watch the cpu load after closing the
        window. It should fall to zero since the component displaying the gif is
        no longer visible (the JWindow is "disposed" and its ref is null'd, and
        the JLabel ref is even null'd!)

        --------------------

        The test case is attached to this bug report.

        Note: I did try this on 1.2 and the CPU usage drops to zero as expected, so this is a regression.

              peterz Peter Zhelezniakov
              stewilso Steve Wilson (Inactive)
              Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

                Created:
                Updated:
                Resolved:
                Imported:
                Indexed: