harmony-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Tony Wu (JIRA)" <j...@apache.org>
Subject [jira] Commented: (HARMONY-2475) [classlib][archive] java.util.zip.Inflater.inflate(byte[]) throws DataFormatException when input data is not specified
Date Thu, 25 Jan 2007 03:25:49 GMT

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

Tony Wu commented on HARMONY-2475:
----------------------------------

I can not reproduce it on both winxp sp2 and ubuntu with latest classlib. 
Maybe it is not a bug now.

> [classlib][archive] java.util.zip.Inflater.inflate(byte[]) throws DataFormatException
when input data is not specified
> ----------------------------------------------------------------------------------------------------------------------
>
>                 Key: HARMONY-2475
>                 URL: https://issues.apache.org/jira/browse/HARMONY-2475
>             Project: Harmony
>          Issue Type: Bug
>          Components: Classlib
>            Reporter: Anton Ivanov
>            Priority: Minor
>
> If input data is not specified and we try to call Inflater.inflate(byte[]) method DataFormatException
is thrown. RI does not throw DataFormatException in such a case.
> The test to reproduce the problem:
> import java.util.zip.Inflater;
> public class InflaterTest  {
>     public static void main(String[] args) throws InterruptedException {
>         Inflater inf = new Inflater();
>         byte[] ba = new byte[100];
>         try {
>             int length = inf.inflate(ba);
>             System.out.println("PASSED");
>             System.out.println("number of bytes uncompressed: " + length);
>         } catch (Exception e) {
>             System.out.println("FAILED");
>             e.printStackTrace();
>         }
>     }
> }
> Output on Harmony:
> FAILED
> java.util.zip.DataFormatException:
>         at java.util.zip.Inflater.inflateImpl(Native Method)
>         at java.util.zip.Inflater.inflate(Inflater.java:180)
>         at java.util.zip.Inflater.inflate(Inflater.java:149)
>         at InflaterTest.main(InflaterTest.java:11)
> Output on RI:
> PASSED
> number of bytes uncompressed: 0

-- 
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