harmony-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Nathan Beyer (JIRA)" <j...@apache.org>
Subject [jira] Assigned: (HARMONY-605) [classlib][util] java.util.jar.getManifest() doesn't throw IllegalStateException if the jar file has been closed
Date Fri, 16 Jun 2006 01:09:30 GMT
     [ http://issues.apache.org/jira/browse/HARMONY-605?page=all ]

Nathan Beyer reassigned HARMONY-605:
------------------------------------

    Assign To: Nathan Beyer

>  [classlib][util] java.util.jar.getManifest() doesn't throw IllegalStateException if
the jar file has been closed
> -----------------------------------------------------------------------------------------------------------------
>
>          Key: HARMONY-605
>          URL: http://issues.apache.org/jira/browse/HARMONY-605
>      Project: Harmony
>         Type: Bug

>     Reporter: Vladimir Ivanov
>     Assignee: Nathan Beyer
>  Attachments: JarFile.diffs, JarFileTest.diff, ZipFile.diffs
>
> Compatibility issue: Harmony java.util.jar.getManifest() doesn't throw IllegalStateException
if the jar file has been closed while RI does.
> According to J2SE specification
> IllegalStateException - may be thrown if the jar file has been closed
> =========================== test.java
> import java.io.File; 
> import java.util.jar.JarFile; 
> public class test {          
>     public static void main(String args[]) throws Exception { 
>         try { 
>             File f = new File("FilenoManifest.jar"); 
>             JarFile jf = new JarFile(f, false); 
>             jf.close(); 
>             jf.getManifest(); 
>             System.out.println("Failed");
>         } catch (IllegalStateException e) {
>             System.out.println("Passed");
>         } 
>     } 
> }
> Steps to Reproduce: 
> 1.Compile test.java 
> % javac -d test.java
> 2. create jar file "FileNoManifest.jar" without manifest  
> 3. Run test class
> The output on Harmony: 
> Failed 
> The output on RI: 
> passed
>  

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
   http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see:
   http://www.atlassian.com/software/jira


Mime
View raw message