harmony-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Leo Li (JIRA)" <j...@apache.org>
Subject [jira] Closed: (HARMONY-3436) [classlib][luni]java.net.JarURLConnection gets different jarFile when the inputstream has been closed if cache is not used.
Date Fri, 13 Apr 2007 02:38:16 GMT

     [ https://issues.apache.org/jira/browse/HARMONY-3436?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]

Leo Li closed HARMONY-3436.
---------------------------


> [classlib][luni]java.net.JarURLConnection gets different jarFile when the inputstream
has been closed if cache is not used.
> ---------------------------------------------------------------------------------------------------------------------------
>
>                 Key: HARMONY-3436
>                 URL: https://issues.apache.org/jira/browse/HARMONY-3436
>             Project: Harmony
>          Issue Type: Bug
>          Components: Classlib
>            Reporter: Leo Li
>         Assigned To: Paulex Yang
>         Attachments: patch-3436.diff
>
>
> Here is an example:
> public void test() throws Exception
>     { 
>       URL url = new URL("jar:file:Test.jar!/test.class");
>       JarURLConnection connection = (JarURLConnection) url.openConnection();
>       connection.setUseCaches(false);
>         InputStream in = connection.getInputStream();
>         JarFile jarFile1 = connection.getJarFile();
>        byte[] data = new byte[1024];
>         while(in.read(data)>=0);
>         in.close(); 
>         JarFile jarFile2 = connection1.getJarFile();
>         assertSame(jarFile1, jarFile2);
>  }
> RI passes.
> Harmony fails.

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