-
Bug
-
Resolution: Won't Fix
-
P2
-
5.0u18
-
None
-
sparc
-
solaris_7
We are using ImageIO in one of our products and are experiencing OutOfMemory errors from what appears to be a native memory leak. The Java Heap is fine at the point of the error. Here is a stack trace from one of the crashes:
------------------
Root Cause: java.lang.OutOfMemoryError
at java.util.zip.Deflater.init(Native Method)
at java.util.zip.Deflater.<init>(Deflater.java:117)
at java.util.zip.Deflater.<init>(Deflater.java:126)
at com.sun.imageio.plugins.png.IDATOutputStream.<init>(PNGImageWriter.java:139)
at com.sun.imageio.plugins.png.PNGImageWriter.write_IDAT(PNGImageWriter.java:894)
at com.sun.imageio.plugins.png.PNGImageWriter.write(PNGImageWriter.java:1123)
at javax.imageio.ImageWriter.write(ImageWriter.java:598)
at javax.imageio.ImageIO.write(ImageIO.java:1450)
at javax.imageio.ImageIO.write(ImageIO.java:1524)
Here is the relevant code from the PNG package:
----------------
package com.sun.imageio.plugins.png;
import java.io.IOException;
import java.util.zip.Deflater;
import javax.imageio.stream.ImageOutputStream;
import javax.imageio.stream.ImageOutputStreamImpl;
// Referenced classes of package com.sun.imageio.plugins.png:\
// CRC
class IDATOutputStream extends ImageOutputStreamImpl
{
public IDATOutputStream(ImageOutputStream imageoutputstream, int i)
throws IOException
{
crc = new CRC();
def = new Deflater(9);
buf = new byte[512];
stream = imageoutputstream;
chunkLength = i;
startChunk();
}
We believe the following bug is applicable:
http://bugs.sun.com/bugdatabase/view_bug.do?bug_id=4797189
------------------
Root Cause: java.lang.OutOfMemoryError
at java.util.zip.Deflater.init(Native Method)
at java.util.zip.Deflater.<init>(Deflater.java:117)
at java.util.zip.Deflater.<init>(Deflater.java:126)
at com.sun.imageio.plugins.png.IDATOutputStream.<init>(PNGImageWriter.java:139)
at com.sun.imageio.plugins.png.PNGImageWriter.write_IDAT(PNGImageWriter.java:894)
at com.sun.imageio.plugins.png.PNGImageWriter.write(PNGImageWriter.java:1123)
at javax.imageio.ImageWriter.write(ImageWriter.java:598)
at javax.imageio.ImageIO.write(ImageIO.java:1450)
at javax.imageio.ImageIO.write(ImageIO.java:1524)
Here is the relevant code from the PNG package:
----------------
package com.sun.imageio.plugins.png;
import java.io.IOException;
import java.util.zip.Deflater;
import javax.imageio.stream.ImageOutputStream;
import javax.imageio.stream.ImageOutputStreamImpl;
// Referenced classes of package com.sun.imageio.plugins.png:\
// CRC
class IDATOutputStream extends ImageOutputStreamImpl
{
public IDATOutputStream(ImageOutputStream imageoutputstream, int i)
throws IOException
{
crc = new CRC();
def = new Deflater(9);
buf = new byte[512];
stream = imageoutputstream;
chunkLength = i;
startChunk();
}
We believe the following bug is applicable:
http://bugs.sun.com/bugdatabase/view_bug.do?bug_id=4797189
- relates to
-
JDK-5092131 using 1 MB pagesize throws "not enough space" error with 32bit JVM
- Closed
-
JDK-4797189 Finalizers not called promptly enough
- Closed