From: Hulse, M. <mh...@ca...> - 2004-09-22 17:58:07
|
Hi, I'm kind of new to using zip in Java so please excuse. I have just downloaded jazzlib 0.07 and I am trying to unzip a file that I can mount in NetBeans and see it's contents. My error is net.sf.jazzlib.ZipException: Wrong Local header signature: a5a4d java/lang/Throwable.<init>(Ljava/lang/String;)V+4 (Throwable.java:85) java/lang/Exception.<init>(Ljava/lang/String;)V+1 (Exception.java:33) java/io/IOException.<init>(Ljava/lang/String;)V+1 (IOException.java:38) net/sf/jazzlib/ZipException.<init>(Ljava/lang/String;)V+1 (ZipException.java:70) net/sf/jazzlib/ZipInputStream.getNextEntry()Lnet/sf/jazzlib/ZipEntry;+77(Zip InputStream.java:156) com/cavtel/rswt/CopyIFStoDB400rcl.getZipStream(Lcom/ibm/as400/access/IFSJava File;)Lnet/sf/jazzlib/ZipInputStream;+0 (CopyIF StoDB400rcl.java:343) com/cavtel/rswt/CopyIFStoDB400rcl.copyIFS()V+0 (CopyIFStoDB400rcl.java:80) com/cavtel/Util/DataQueTestMonitorRecl.main([Ljava/lang/String;)V+0 (DataQueTestMonitorRecl.java:25) My code is: try{ zipin = new ZipInputStream(new FileInputStream(_ifsjf.getAbsolutePath())); ZipEntry ze = null; ze = zipin.getNextEntry(); System.out.println("zipin.available(): " + zipin.available()); System.out.println("Zip getName: " + ze.getName()); System.out.println("Zip getCompressedSize: " + ze.getCompressedSize()); System.out.println("Zip getCrc: " + ze.getCrc()); System.out.println("Zip getSize: " + ze.getSize()); System.out.println("Zip isDirectory: " + ze.isDirectory()); System.out.println("Zip toString: " + ze.toString()); } If there is something else I need to do please let me know. If this looks ok then why can NetBeans read it? I'm just stuck. Any help would be appreciated. Thanks, Mike |