harmony-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Vladimir Beliaev (JIRA)" <j...@apache.org>
Subject [jira] Commented: (HARMONY-1831) [drlvm][reliability] IllegalArgumentException on GZIPOutputStream()
Date Tue, 30 Jan 2007 16:18:33 GMT

    [ https://issues.apache.org/jira/browse/HARMONY-1831?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_12468664
] 

Vladimir Beliaev commented on HARMONY-1831:
-------------------------------------------

The bug is reproducible on both recent version of DRLVM and IBM VM with Harmony classlib.
So it looks like classlib issue, not DRLVM one.

The bug is caused by fact, that zlib function - deflateInit2 - (which is called from Harmony
classlib implementation of native method Deflater.createStream) returns error: Z_MEM_ERROR.


Later investigation is required, still the bug may be caused by out-of-memory cause. At least
one issue exist in createStream - it must check the returned error value and throw the proper
exception - like it throws IllegalArgumentException in the issue above but it must throw OutOfMemoryError.

========================================
IBM J9 VM with classlib output on Windows/IA32:
Iterations: 0
Iterations: 1000
Iterations: 2000
Iterations: 3000
Iterations: 4000
Iterations: 5000
Exception in thread "main" java.lang.IllegalArgumentException: 
        at java.util.zip.Deflater.createStream(Native Method)
        at java.util.zip.Deflater.<init>(Deflater.java:112)
        at java.util.zip.GZIPOutputStream.<init>(GZIPOutputStream.java:53)
        at java.util.zip.GZIPOutputStream.<init>(GZIPOutputStream.java:40)
        at GZIPOutputStreamTest.main(GZIPOutputStreamTest.java:11)

Please move this bug to classlib category.

Thanks
Vladimir Beliaev

> [drlvm][reliability] IllegalArgumentException on GZIPOutputStream()
> -------------------------------------------------------------------
>
>                 Key: HARMONY-1831
>                 URL: https://issues.apache.org/jira/browse/HARMONY-1831
>             Project: Harmony
>          Issue Type: Bug
>          Components: DRLVM
>            Reporter: Nikolay Bannikov
>
> IllegalArgumentException on invocation GZIPOutputStream().
> Note, that all works fine on RI.
>  
> Code for reproducing:
> import java.io.ByteArrayOutputStream;
> import java.io.IOException;
> import java.util.zip.GZIPOutputStream;
>  
> public class GZIPOutputStreamTest {
>     public static void main(String args[]) throws IOException {
>         int i = 0;
>         ByteArrayOutputStream os = new ByteArrayOutputStream(1000);
>         for(i = 0; i < 50000; i++ ) {
>             new GZIPOutputStream(os);
>             if (i % 1000 == 0) {
>                 System.out.println("Iterations: " + i);
>             }
>         }
>     }
> }
>  
> HARMONY output:
> =============
> Apache Harmony Launcher : (c) Copyright 1991, 2006 The Apache Software Foundation or
its licensors, as applicable.
> java version "1.5.0"
> pre-alpha : not complete or compatible
> svn = r450941, (Sep 28 2006), Windows/ia32/msvc 1310, release build http://incubator.apache.org/harmony
> Iterations: 0
> Iterations: 1000
> Iterations: 2000
> Iterations: 3000
> Iterations: 4000
> JNI.ExceptionDescribe: java/lang/IllegalArgumentException:
>  
> java/lang/IllegalArgumentException :
>  at java.util.zip.Deflater.createStream (Deflater.java: -2)
>  at java.util.zip.Deflater.<init> (Deflater.java: 374)
>  at java.util.zip.GZIPOutputStream.<init> (GZIPOutputStream.java: 51)
>  at java.util.zip.GZIPOutputStream.<init> (GZIPOutputStream.java: 39)
>  at GZIPOutputStreamTest.main (GZIPOutputStreamTest.java: 10)
> Error occured while running starter class: Exception left unhandled before destroying
VM
> JNI.ExceptionDescribe: java/lang/IllegalArgumentException:
>  
> java/lang/IllegalArgumentException :
>  at java.util.zip.Deflater.createStream (Deflater.java: -2)
>  at java.util.zip.Deflater.<init> (Deflater.java: 374)
>  at java.util.zip.GZIPOutputStream.<init> (GZIPOutputStream.java: 51)
>  at java.util.zip.GZIPOutputStream.<init> (GZIPOutputStream.java: 39)
>  at GZIPOutputStreamTest.main (GZIPOutputStreamTest.java: 10)
> Error occured in starter class shutdown() method.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


Mime
View raw message