commons-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Pavithra Kumar (Commented) (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (COMPRESS-168) getName of ZipArchiveEntry
Date Tue, 13 Dec 2011 03:33:31 GMT

    [ https://issues.apache.org/jira/browse/COMPRESS-168?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13168102#comment-13168102
] 

Pavithra Kumar commented on COMPRESS-168:
-----------------------------------------

    public static void main(String args[]){
        try{
            String zipname = "D:\\Pavis\\TestUnZip\\TestZip.zip";
            ZipFile zFile = new ZipFile(zipname);
            Enumeration en = zFile.getEntries();
            long i = 0;
            while(en.hasMoreElements()){
                i += 1;
                ZipArchiveEntry zEntry = (ZipArchiveEntry)en.nextElement();
                System.out.println(zEntry.getName());
                FileOutputStream fout = new FileOutputStream("D:\\Pavis\\TestUnZip\\" + i
+ ".jpg");
                InputStream is = zFile.getInputStream(zEntry);
                for (int c = is.read(); c != -1; c = is.read()) {
                    fout.write(c);
                }
                is.close();
                fout.close();
            }
        }
        catch(Exception e){
            e.printStackTrace();
        }
    }

When I debug I can see the object of ZipArchiveEntry has a different filename for arabic files.

                
> getName of ZipArchiveEntry
> --------------------------
>
>                 Key: COMPRESS-168
>                 URL: https://issues.apache.org/jira/browse/COMPRESS-168
>             Project: Commons Compress
>          Issue Type: Test
>          Components: Archivers
>    Affects Versions: 1.2
>         Environment: J2EE Environment with jdk 1.4
>            Reporter: Pavithra Kumar
>         Attachments: TestZip.zip
>
>
> getName method of ZipArchiveEntry is not giving arabic file names. Instead of that it
gives some chunked characters.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

Mime
View raw message