Same garbage collector bug with java 1.5.0_03 and MS IE
Posted By:
Anonymous
Posted On:
Tuesday, June 28, 2005 04:41 AM
The garbage collector of the JVM does not work properly with applets on IE6.
I have written a slideshow applet, which - in short words - loads an image, scales it to screen-size, and loads the next image when one clicks on the applet.
When using the applet in Internet Explorer 6, the memory allocated by an image is never freed. After about 30-40 images, more tham 100 MB are allocated by the JVM and the JVW crashes throwing an OutOfMemoryError.
The same Applet runs fine on Netscape and Mozilla and also in the standalone applet viewer. Here, the memory allocated is always between 8 and 25 MB, even after sliding through hundreds of images.
I have also tested the applet with BEA's JVM JRockit 1.5.0_02. Same results: IE6 crashes, all other browsers work fine.
It seems to be a bug of the garbage collector, which - however - only occurs when applets run on IE.
I've posted this to SUN, hoping they could give me a workaround to influence the cacheing-behaviour of the JVW. (Image.flush() does not solve the problem.) No answer yet.