PatchSet 6981 
Date: 2005/12/03 15:49:54
Author: guilhem
Branch: HEAD
Tag: (none) 
Log:
Removed spurious backup files from CVS.

Members: 
        ChangeLog:1.4503->1.4504 
        developers/update-vm-list:1.2->1.3 
        libraries/javalib/Makefile.am:1.404->1.405 
        libraries/javalib/Makefile.in:1.500->1.501 
        libraries/javalib/external/classpath/lib/Makefile.am:1.2->1.3 
        libraries/javalib/external/classpath/lib/Makefile.in:1.4->1.5 
        libraries/javalib/vmspecific/java/util/zip/ZipFile.java~:1.1->1.2(DEAD) 
        
libraries/javalib/vmspecific/java/util/zip/ZipInputStream.java~:1.1->1.2(DEAD) 
        
libraries/javalib/vmspecific/java/util/zip/ZipOutputStream.java~:1.1->1.2(DEAD) 
        
libraries/javalib/vmspecific/org/kaffe/security/provider/SHA1PRNG.java~:1.1->1.2(DEAD)
 
        
libraries/javalib/vmspecific/org/kaffe/tools/jar/Jar.java~:1.1->1.2(DEAD) 
        
libraries/javalib/vmspecific/org/kaffe/util/log/LogStream.java~:1.1->1.2(DEAD) 
        
libraries/javalib/vmspecific/org/kaffe/util/log/SimpleLogViewer.java~:1.1->1.2(DEAD)
 

Index: kaffe/ChangeLog
diff -u kaffe/ChangeLog:1.4503 kaffe/ChangeLog:1.4504
--- kaffe/ChangeLog:1.4503      Sat Dec  3 12:54:16 2005
+++ kaffe/ChangeLog     Sat Dec  3 15:49:54 2005
@@ -1,5 +1,16 @@
 2005-12-03  Guilhem Lavaux  <[EMAIL PROTECTED]>
 
+       * Removed a few spurious backup files from
+       libraries/javalib/vmspecific
+
+       * libraries/javalib/Makefile.am,
+       libraries/javalib/Makefile.in:
+       Regenerated.
+
+       * developers/update-vm-list: Updated to forget backup files.
+
+2005-12-03  Guilhem Lavaux  <[EMAIL PROTECTED]>
+
        * configure.ac: Added a new option "--with-ecj" to be able
        to compile with ecj. Reworked the java compiler detection.
        
Index: kaffe/developers/update-vm-list
diff -u kaffe/developers/update-vm-list:1.2 kaffe/developers/update-vm-list:1.3
--- kaffe/developers/update-vm-list:1.2 Sat Oct 22 10:08:15 2005
+++ kaffe/developers/update-vm-list     Sat Dec  3 15:49:58 2005
@@ -1,3 +1,3 @@
 cp Makefile.am.in Makefile.am
-find vmspecific/ -name CVS -prune -o -type f -print | sed \
+find vmspecific/ -name CVS -prune -o '(' -type f -a ! -name "*~" ')' -print | 
sed \
 's/^/\t/g; s/$/ \\/;$s/ \\$//' >> Makefile.am
Index: kaffe/libraries/javalib/Makefile.am
diff -u kaffe/libraries/javalib/Makefile.am:1.404 
kaffe/libraries/javalib/Makefile.am:1.405
--- kaffe/libraries/javalib/Makefile.am:1.404   Sat Dec  3 12:55:04 2005
+++ kaffe/libraries/javalib/Makefile.am Sat Dec  3 15:49:58 2005
@@ -652,20 +652,13 @@
        vmspecific/gnu/java/net/DNSJavaInetAddressImpl.java \
        vmspecific/gnu/java/net/InetAddressImpl.java \
        vmspecific/gnu/java/net/PlainDatagramSocketImpl.java \
-       vmspecific/gnu/java/net/PlainDatagramSocketImpl.java~ \
        vmspecific/gnu/java/net/PlainSocketImpl.java \
-       vmspecific/gnu/java/net/PlainSocketImpl.java~ \
        vmspecific/gnu/java/net/SysInetAddressImpl.java \
        vmspecific/gnu/java/nio/VMPipe.java \
-       vmspecific/gnu/java/nio/VMPipe.java~ \
        vmspecific/gnu/java/nio/VMSelector.java \
-       vmspecific/gnu/java/nio/VMSelector.java~ \
        vmspecific/java/io/VMFile.java \
-       vmspecific/java/io/VMFile.java~ \
        vmspecific/java/io/VMObjectInputStream.java \
-       vmspecific/java/io/VMObjectInputStream.java~ \
        vmspecific/java/io/VMObjectStreamClass.java \
-       vmspecific/java/io/VMObjectStreamClass.java~ \
        vmspecific/java/lang/Class.java \
        vmspecific/java/lang/ClassLoader.java \
        vmspecific/java/lang/Runtime.java \
@@ -674,9 +667,7 @@
        vmspecific/java/lang/VMClassLoader.java \
        vmspecific/java/lang/VMCompiler.java \
        vmspecific/java/lang/VMDouble.java \
-       vmspecific/java/lang/VMDouble.java~ \
        vmspecific/java/lang/VMFloat.java \
-       vmspecific/java/lang/VMFloat.java~ \
        vmspecific/java/lang/VMObject.java \
        vmspecific/java/lang/VMProcess.java \
        vmspecific/java/lang/VMRuntime.java \
@@ -691,16 +682,12 @@
        vmspecific/java/lang/reflect/VMProxy.java \
        vmspecific/java/net/InetAddress.java \
        vmspecific/java/net/VMInetAddress.java \
-       vmspecific/java/net/VMInetAddress.java~ \
        vmspecific/java/net/VMNetworkInterface.java \
-       vmspecific/java/net/VMNetworkInterface.java~ \
        vmspecific/java/nio/VMDirectByteBuffer.java \
-       vmspecific/java/nio/VMDirectByteBuffer.java~ \
        vmspecific/java/nio/channels/VMChannels.java \
        vmspecific/java/security/VMAccessController.java \
        vmspecific/java/util/LocaleData.java \
        vmspecific/java/util/VMTimeZone.java \
-       vmspecific/java/util/VMTimeZone.java~ \
        vmspecific/java/util/mime/MimeType.java \
        vmspecific/java/util/mime/MimeTypeParameterList.java \
        vmspecific/java/util/mime/MimeTypeParseException.java \
@@ -711,11 +698,8 @@
        vmspecific/java/util/zip/Inflater.java \
        vmspecific/java/util/zip/ZipEntry.java \
        vmspecific/java/util/zip/ZipFile.java \
-       vmspecific/java/util/zip/ZipFile.java~ \
        vmspecific/java/util/zip/ZipInputStream.java \
-       vmspecific/java/util/zip/ZipInputStream.java~ \
        vmspecific/java/util/zip/ZipOutputStream.java \
-       vmspecific/java/util/zip/ZipOutputStream.java~ \
        vmspecific/org/kaffe/beans/editors/BooleanEditor.java \
        vmspecific/org/kaffe/beans/editors/ByteEditor.java \
        vmspecific/org/kaffe/beans/editors/DoubleEditor.java \
@@ -727,11 +711,8 @@
        vmspecific/org/kaffe/io/AccessibleBAOStream.java \
        vmspecific/org/kaffe/io/NullOutputStream.java \
        vmspecific/org/kaffe/io/StdErrorStream.java \
-       vmspecific/org/kaffe/io/StdErrorStream.java~ \
        vmspecific/org/kaffe/io/StdInputStream.java \
-       vmspecific/org/kaffe/io/StdInputStream.java~ \
        vmspecific/org/kaffe/io/StdOutputStream.java \
-       vmspecific/org/kaffe/io/StdOutputStream.java~ \
        vmspecific/org/kaffe/jar/ExecJar.java \
        vmspecific/org/kaffe/jar/ExecJarName.java \
        vmspecific/org/kaffe/lang/ClassPathReader.java \
@@ -748,16 +729,13 @@
        vmspecific/org/kaffe/security/Randomness.java \
        vmspecific/org/kaffe/security/UnixRandomness.java \
        vmspecific/org/kaffe/security/provider/Kaffe.java \
-       vmspecific/org/kaffe/security/provider/Kaffe.java~ \
        vmspecific/org/kaffe/security/provider/MD2.java \
        vmspecific/org/kaffe/security/provider/MD4.java \
        vmspecific/org/kaffe/security/provider/MD5.java \
        vmspecific/org/kaffe/security/provider/SHA.java \
        vmspecific/org/kaffe/security/provider/SHA1PRNG.java \
-       vmspecific/org/kaffe/security/provider/SHA1PRNG.java~ \
        vmspecific/org/kaffe/security/provider/UpdateDigest.java \
        vmspecific/org/kaffe/tools/jar/Jar.java \
-       vmspecific/org/kaffe/tools/jar/Jar.java~ \
        vmspecific/org/kaffe/tools/jar/XPFile.java \
        vmspecific/org/kaffe/tools/jar/XPFileInputStream.java \
        vmspecific/org/kaffe/tools/jar/XPFileOutputStream.java \
@@ -802,9 +780,7 @@
        vmspecific/org/kaffe/util/locale/Language_zh.java \
        vmspecific/org/kaffe/util/log/LogClient.java \
        vmspecific/org/kaffe/util/log/LogStream.java \
-       vmspecific/org/kaffe/util/log/LogStream.java~ \
        vmspecific/org/kaffe/util/log/SimpleLogViewer.java \
-       vmspecific/org/kaffe/util/log/SimpleLogViewer.java~ \
        vmspecific/org/kaffe/util/zip/SwitchInflater.java \
        vmspecific/org/metastatic/jessie/Base64.java \
        vmspecific/org/metastatic/jessie/CertificateHandler.java \
Index: kaffe/libraries/javalib/Makefile.in
diff -u kaffe/libraries/javalib/Makefile.in:1.500 
kaffe/libraries/javalib/Makefile.in:1.501
--- kaffe/libraries/javalib/Makefile.in:1.500   Sat Dec  3 12:55:06 2005
+++ kaffe/libraries/javalib/Makefile.in Sat Dec  3 15:49:59 2005
@@ -968,20 +968,13 @@
        vmspecific/gnu/java/net/DNSJavaInetAddressImpl.java \
        vmspecific/gnu/java/net/InetAddressImpl.java \
        vmspecific/gnu/java/net/PlainDatagramSocketImpl.java \
-       vmspecific/gnu/java/net/PlainDatagramSocketImpl.java~ \
        vmspecific/gnu/java/net/PlainSocketImpl.java \
-       vmspecific/gnu/java/net/PlainSocketImpl.java~ \
        vmspecific/gnu/java/net/SysInetAddressImpl.java \
        vmspecific/gnu/java/nio/VMPipe.java \
-       vmspecific/gnu/java/nio/VMPipe.java~ \
        vmspecific/gnu/java/nio/VMSelector.java \
-       vmspecific/gnu/java/nio/VMSelector.java~ \
        vmspecific/java/io/VMFile.java \
-       vmspecific/java/io/VMFile.java~ \
        vmspecific/java/io/VMObjectInputStream.java \
-       vmspecific/java/io/VMObjectInputStream.java~ \
        vmspecific/java/io/VMObjectStreamClass.java \
-       vmspecific/java/io/VMObjectStreamClass.java~ \
        vmspecific/java/lang/Class.java \
        vmspecific/java/lang/ClassLoader.java \
        vmspecific/java/lang/Runtime.java \
@@ -990,9 +983,7 @@
        vmspecific/java/lang/VMClassLoader.java \
        vmspecific/java/lang/VMCompiler.java \
        vmspecific/java/lang/VMDouble.java \
-       vmspecific/java/lang/VMDouble.java~ \
        vmspecific/java/lang/VMFloat.java \
-       vmspecific/java/lang/VMFloat.java~ \
        vmspecific/java/lang/VMObject.java \
        vmspecific/java/lang/VMProcess.java \
        vmspecific/java/lang/VMRuntime.java \
@@ -1007,16 +998,12 @@
        vmspecific/java/lang/reflect/VMProxy.java \
        vmspecific/java/net/InetAddress.java \
        vmspecific/java/net/VMInetAddress.java \
-       vmspecific/java/net/VMInetAddress.java~ \
        vmspecific/java/net/VMNetworkInterface.java \
-       vmspecific/java/net/VMNetworkInterface.java~ \
        vmspecific/java/nio/VMDirectByteBuffer.java \
-       vmspecific/java/nio/VMDirectByteBuffer.java~ \
        vmspecific/java/nio/channels/VMChannels.java \
        vmspecific/java/security/VMAccessController.java \
        vmspecific/java/util/LocaleData.java \
        vmspecific/java/util/VMTimeZone.java \
-       vmspecific/java/util/VMTimeZone.java~ \
        vmspecific/java/util/mime/MimeType.java \
        vmspecific/java/util/mime/MimeTypeParameterList.java \
        vmspecific/java/util/mime/MimeTypeParseException.java \
@@ -1027,11 +1014,8 @@
        vmspecific/java/util/zip/Inflater.java \
        vmspecific/java/util/zip/ZipEntry.java \
        vmspecific/java/util/zip/ZipFile.java \
-       vmspecific/java/util/zip/ZipFile.java~ \
        vmspecific/java/util/zip/ZipInputStream.java \
-       vmspecific/java/util/zip/ZipInputStream.java~ \
        vmspecific/java/util/zip/ZipOutputStream.java \
-       vmspecific/java/util/zip/ZipOutputStream.java~ \
        vmspecific/org/kaffe/beans/editors/BooleanEditor.java \
        vmspecific/org/kaffe/beans/editors/ByteEditor.java \
        vmspecific/org/kaffe/beans/editors/DoubleEditor.java \
@@ -1043,11 +1027,8 @@
        vmspecific/org/kaffe/io/AccessibleBAOStream.java \
        vmspecific/org/kaffe/io/NullOutputStream.java \
        vmspecific/org/kaffe/io/StdErrorStream.java \
-       vmspecific/org/kaffe/io/StdErrorStream.java~ \
        vmspecific/org/kaffe/io/StdInputStream.java \
-       vmspecific/org/kaffe/io/StdInputStream.java~ \
        vmspecific/org/kaffe/io/StdOutputStream.java \
-       vmspecific/org/kaffe/io/StdOutputStream.java~ \
        vmspecific/org/kaffe/jar/ExecJar.java \
        vmspecific/org/kaffe/jar/ExecJarName.java \
        vmspecific/org/kaffe/lang/ClassPathReader.java \
@@ -1064,16 +1045,13 @@
        vmspecific/org/kaffe/security/Randomness.java \
        vmspecific/org/kaffe/security/UnixRandomness.java \
        vmspecific/org/kaffe/security/provider/Kaffe.java \
-       vmspecific/org/kaffe/security/provider/Kaffe.java~ \
        vmspecific/org/kaffe/security/provider/MD2.java \
        vmspecific/org/kaffe/security/provider/MD4.java \
        vmspecific/org/kaffe/security/provider/MD5.java \
        vmspecific/org/kaffe/security/provider/SHA.java \
        vmspecific/org/kaffe/security/provider/SHA1PRNG.java \
-       vmspecific/org/kaffe/security/provider/SHA1PRNG.java~ \
        vmspecific/org/kaffe/security/provider/UpdateDigest.java \
        vmspecific/org/kaffe/tools/jar/Jar.java \
-       vmspecific/org/kaffe/tools/jar/Jar.java~ \
        vmspecific/org/kaffe/tools/jar/XPFile.java \
        vmspecific/org/kaffe/tools/jar/XPFileInputStream.java \
        vmspecific/org/kaffe/tools/jar/XPFileOutputStream.java \
@@ -1118,9 +1096,7 @@
        vmspecific/org/kaffe/util/locale/Language_zh.java \
        vmspecific/org/kaffe/util/log/LogClient.java \
        vmspecific/org/kaffe/util/log/LogStream.java \
-       vmspecific/org/kaffe/util/log/LogStream.java~ \
        vmspecific/org/kaffe/util/log/SimpleLogViewer.java \
-       vmspecific/org/kaffe/util/log/SimpleLogViewer.java~ \
        vmspecific/org/kaffe/util/zip/SwitchInflater.java \
        vmspecific/org/metastatic/jessie/Base64.java \
        vmspecific/org/metastatic/jessie/CertificateHandler.java \
Index: kaffe/libraries/javalib/external/classpath/lib/Makefile.am
diff -u kaffe/libraries/javalib/external/classpath/lib/Makefile.am:1.2 
kaffe/libraries/javalib/external/classpath/lib/Makefile.am:1.3
--- kaffe/libraries/javalib/external/classpath/lib/Makefile.am:1.2      Sat Nov 
26 20:30:20 2005
+++ kaffe/libraries/javalib/external/classpath/lib/Makefile.am  Sat Dec  3 
15:50:04 2005
@@ -153,10 +153,10 @@
 
 dist-hook:
        mkdir -p $(distdir)
-       cp -dfR $(top_srcdir)/gnu $(top_srcdir)/java $(top_srcdir)/javax 
$(top_srcdir)/org $(top_srcdir)/vm $(top_srcdir)/resource $(top_distdir)
+       cp -dfR $(top_srcdir)/gnu $(top_srcdir)/java $(top_srcdir)/javax 
$(top_srcdir)/org $(top_srcdir)/vm $(top_srcdir)/resource $(distdir)/..
 # Delete not wanted files.
-       $(FIND) $(top_distdir)/gnu $(top_distdir)/java $(top_distdir)/javax 
$(top_distdir)/org $(top_distdir)/vm $(top_distdir)/resource -name CVS -print | 
xargs rm -fr
-       $(FIND) $(top_distdir)/gnu $(top_distdir)/java $(top_distdir)/javax 
$(top_distdir)/org $(top_distdir)/vm $(top_distdir)/resource -name .cvsignore 
-print | xargs rm -f
-       $(FIND) $(top_distdir)/gnu $(top_distdir)/java $(top_distdir)/javax 
$(top_distdir)/org $(top_distdir)/vm -name class-dependencies.conf -print | 
xargs rm -f
-       rm -f $(top_distdir)/gnu/classpath/Configuration.java
-       rm -f $(top_distdir)/java/util/LocaleData.java
+       $(FIND) $(distdir)/../gnu $(distdir)/../java $(distdir)/../javax 
$(distdir)/../org $(distdir)/../vm $(distdir)/../resource -name CVS -print | 
xargs rm -fr
+       $(FIND) $(distdir)/../gnu $(distdir)/../java $(distdir)/../javax 
$(distdir)/../org $(distdir)/../vm $(distdir)/../resource -name .cvsignore 
-print | xargs rm -f
+       $(FIND) $(distdir)/../gnu $(distdir)/../java $(distdir)/../javax 
$(distdir)/../org $(distdir)/../vm -name class-dependencies.conf -print | xargs 
rm -f
+       rm -f $(distdir)/../gnu/classpath/Configuration.java
+       rm -f $(distdir)/../java/util/LocaleData.java
Index: kaffe/libraries/javalib/external/classpath/lib/Makefile.in
diff -u kaffe/libraries/javalib/external/classpath/lib/Makefile.in:1.4 
kaffe/libraries/javalib/external/classpath/lib/Makefile.in:1.5
--- kaffe/libraries/javalib/external/classpath/lib/Makefile.in:1.4      Sat Nov 
26 20:30:20 2005
+++ kaffe/libraries/javalib/external/classpath/lib/Makefile.in  Sat Dec  3 
15:50:04 2005
@@ -561,13 +561,13 @@
 
 dist-hook:
        mkdir -p $(distdir)
-       cp -dfR $(top_srcdir)/gnu $(top_srcdir)/java $(top_srcdir)/javax 
$(top_srcdir)/org $(top_srcdir)/vm $(top_srcdir)/resource $(top_distdir)
+       cp -dfR $(top_srcdir)/gnu $(top_srcdir)/java $(top_srcdir)/javax 
$(top_srcdir)/org $(top_srcdir)/vm $(top_srcdir)/resource $(distdir)/..
 # Delete not wanted files.
-       $(FIND) $(top_distdir)/gnu $(top_distdir)/java $(top_distdir)/javax 
$(top_distdir)/org $(top_distdir)/vm $(top_distdir)/resource -name CVS -print | 
xargs rm -fr
-       $(FIND) $(top_distdir)/gnu $(top_distdir)/java $(top_distdir)/javax 
$(top_distdir)/org $(top_distdir)/vm $(top_distdir)/resource -name .cvsignore 
-print | xargs rm -f
-       $(FIND) $(top_distdir)/gnu $(top_distdir)/java $(top_distdir)/javax 
$(top_distdir)/org $(top_distdir)/vm -name class-dependencies.conf -print | 
xargs rm -f
-       rm -f $(top_distdir)/gnu/classpath/Configuration.java
-       rm -f $(top_distdir)/java/util/LocaleData.java
+       $(FIND) $(distdir)/../gnu $(distdir)/../java $(distdir)/../javax 
$(distdir)/../org $(distdir)/../vm $(distdir)/../resource -name CVS -print | 
xargs rm -fr
+       $(FIND) $(distdir)/../gnu $(distdir)/../java $(distdir)/../javax 
$(distdir)/../org $(distdir)/../vm $(distdir)/../resource -name .cvsignore 
-print | xargs rm -f
+       $(FIND) $(distdir)/../gnu $(distdir)/../java $(distdir)/../javax 
$(distdir)/../org $(distdir)/../vm -name class-dependencies.conf -print | xargs 
rm -f
+       rm -f $(distdir)/../gnu/classpath/Configuration.java
+       rm -f $(distdir)/../java/util/LocaleData.java
 # Tell versions [3.59,3.63) of GNU make to not export all variables.
 # Otherwise a system limit (for SysV at least) may be exceeded.
 .NOEXPORT:
===================================================================
Checking out kaffe/libraries/javalib/vmspecific/java/util/zip/ZipFile.java~
RCS:  
/home/cvs/kaffe/kaffe/libraries/javalib/vmspecific/java/util/zip/Attic/ZipFile.java~,v
VERS: 1.1
***************
--- kaffe/libraries/javalib/vmspecific/java/util/zip/ZipFile.java~      Sat Dec 
 3 15:57:41 2005
+++ /dev/null   Sun Aug  4 19:57:58 2002
@@ -1,143 +0,0 @@
-/*
- * Java core library component.
- *
- * Copyright (c) 1997, 1998
- *      Transvirtual Technologies, Inc.  All rights reserved.
- *
- * See the file "license.terms" for information on usage and redistribution
- * of this file.
- */
-
-package java.util.zip;
-
-import java.io.ByteArrayInputStream;
-import java.io.File;
-import java.io.IOException;
-import java.io.InputStream;
-import java.util.Enumeration;
-import java.util.Vector;
-
-import kaffe.util.Ptr;
-
-public class ZipFile implements ZipConstants {
-
-
-  /**
-   * Mode flag to open a zip file for reading.
-   * From GNU Classpath.
-   */
-  public static final int OPEN_READ = 0x1;
-
-  /**
-   * Mode flag to delete a zip file after reading.
-   * From GNU Classpath.
-   */
-  public static final int OPEN_DELETE = 0x4;
-
-  // Name of this zip file.
-  private final String name;
-
-  private Ptr zip;
-
-  private boolean closed;
-
-public ZipFile(String fname) throws IOException
-{
-       name = fname;
-       /* only have one thread at a time attempt to open the zip file */
-       zip = openZipFile0(fname);
-       if (zip == null) {
-               throw new IOException("No such zip file " + fname);
-       }
-}
-
-public ZipFile(File f) throws ZipException, IOException
-{
-       this(f.getPath());
-}
-
-public ZipFile(File f, int mode) throws ZipException, IOException
-{
-       // XXX ignoring mode for now
-       this(f);
-}
-
-private void checkIfClosed()
-{
-  if (closed) {
-    throw new IllegalStateException("Zip file already closed: " + getName());
-  }
-}
-
-public void close() throws IOException
-{
-       if (!closed) {
-               closeZipFile0(zip);
-               closed = true;
-       }
-}
-
-public Enumeration entries()
-{
-  checkIfClosed();
-  Vector all = getZipEntries0(zip);
-  return (all.elements());
-}
-
-public ZipEntry getEntry(String zname)
-{
-  checkIfClosed();
-  return (getZipEntry0(zip, zname));
-}
-
-public InputStream getInputStream(ZipEntry ze) throws IOException
-{
-       if (ze == null) {
-               throw new NullPointerException();
-       }
-
-       if (ze.getSize() == -1) {
-               ze = getEntry(ze.getName());
-       }
-
-       if (ze == null) {
-               return null;
-       }
-
-       byte[] buf = getZipData0(zip, ze);
-       if (buf == null) {
-               throw new ZipException("no data");
-       }
-       ByteArrayInputStream strm = new ByteArrayInputStream(buf);
-       return (strm);
-}
-
-public String getName()
-{
-       return (name);
-}
-
-public int size()
-{
-  checkIfClosed();
-  return getZipFileSize0(zip);
-}
-
-protected void finalize() throws IOException
-{
-       /* We don't need to call super.finalize(),
-        * since super class is java.lang.Object, and
-        * java.lang.Object.finalize() just returns
-        * to caller.
-        */
-       close();
-}
-
-private static native Ptr openZipFile0(String fname);
-private static native void closeZipFile0(Ptr zip);
-private static native ZipEntry getZipEntry0(Ptr zip, String zname);
-private static native Vector getZipEntries0(Ptr zip);
-private static native byte[] getZipData0(Ptr zip, ZipEntry ze);
-private static native int getZipFileSize0(Ptr zip);
-
-}
===================================================================
Checking out 
kaffe/libraries/javalib/vmspecific/java/util/zip/ZipInputStream.java~
RCS:  
/home/cvs/kaffe/kaffe/libraries/javalib/vmspecific/java/util/zip/Attic/ZipInputStream.java~,v
VERS: 1.1
***************
--- kaffe/libraries/javalib/vmspecific/java/util/zip/ZipInputStream.java~       
Sat Dec  3 15:57:41 2005
+++ /dev/null   Sun Aug  4 19:57:58 2002
@@ -1,228 +0,0 @@
-
-/*
- * Java core library component.
- *
- * Copyright (c) 1997, 1998
- *      Transvirtual Technologies, Inc.  All rights reserved.
- *
- * See the file "license.terms" for information on usage and redistribution
- * of this file.
- */
-
-package java.util.zip;
-
-import java.io.IOException;
-import java.io.InputStream;
-import java.io.UnsupportedEncodingException;
-
-import kaffe.util.UTF8;
-import kaffe.util.zip.SwitchInflater;
-
-public class ZipInputStream extends InflaterInputStream
-       implements ZipConstants {
-
-  private byte sigbuf[] = new byte[4];
-  private byte zheader[] = new byte[LOCHDR];
-  private byte dheader[] = new byte[EXTHDR];
-  private boolean gotSig;
-  private SwitchInflater sinf;
-  private ZipEntry entry;
-
-  public ZipInputStream(InputStream in) {
-    super(in, new SwitchInflater(true, true));
-    sinf = (SwitchInflater)inf;
-    sinf.reset();
-    sinf.setMode(true);
-    sinf.setLength(Integer.MAX_VALUE);
-  }
-
-  public ZipEntry getNextEntry() throws IOException {
-
-    closeEntry();
-
-    synchronized (this) {
-
-      // First, open the stream.
-      sinf.setLength(Integer.MAX_VALUE);
-
-      // Read next signature
-      int sig = readSig();
-      switch (sig) {
-      case (int)CENSIG:                // central dir: no more entries
-       return null;
-      case (int)LOCSIG:                // another entry
-       break;
-      default:                         // unexpected
-       return null;
-      }
-
-      // Read remainder of local header
-      readFully(zheader, sigbuf.length, zheader.length - sigbuf.length);
-
-      // Read filename; assume UTF-8 encoding
-      byte[] nameBuf = new byte[get16(zheader, LOCNAM)];
-      readFully(nameBuf, 0, nameBuf.length);
-
-      // Read extra field
-      byte[] extra = new byte[get16(zheader, LOCEXT)];
-      readFully(extra, 0, extra.length);
-
-      // Setup new entry
-      entry = createZipEntry(UTF8.decode(nameBuf));
-      entry.version = get16(zheader, LOCVER);
-      entry.flag    = get16(zheader, LOCFLG);
-
-      entry.setMethod(get16(zheader, LOCHOW));
-      entry.setDosTime(get32(zheader, LOCTIM));
-      entry.setCrc(get32(zheader, LOCCRC) & 0xffffffffL);
-
-      entry.setCompressedSize(get32(zheader, LOCSIZ) & 0xffffffffL);
-      entry.setSize(get32(zheader, LOCLEN) & 0xffffffffL);
-
-      entry.setExtra( extra );
-      entry.setComment("");
-      entry.offset = 0;
-
-      // Select the loader, simple or inflater.
-      if (entry.getMethod() == ZipEntry.STORED) {
-       sinf.setMode(true);
-       sinf.setLength((int)entry.getCompressedSize());
-      }
-      else {
-       sinf.setMode(false);
-      }
-
-      //System.out.println("ZipEntry (Post LOC): " + entry + ", meth="
-      // + entry.method + ", size=" + entry.size + ", csize=" + entry.csize
-      // + ", crc=" + entry.crc);
-
-      return entry;
-    }
-  }
-
-  public void closeEntry() throws IOException {
-    synchronized (this) {
-
-      // Don't do this twice
-      if (entry == null)
-       return;
-
-      // Cleanup
-      try {
-
-       // Skip remaining compressed data
-       byte[] buf = new byte[512];
-       while (read(buf, 0, buf.length) != -1);
-
-       // Reset inflate state machine
-       sinf.reset();
-       sinf.setMode(true);
-       sinf.setLength(Integer.MAX_VALUE);
-
-       // In the case where closeEntry() is called after reading
-       // a compressed entry, we need to read the DATA header that
-       // follows, if any, and update the ZipEntry with the info
-       // from the DATA header. This is so that users can find out
-       // the compressed and uncompressed sizes of data written in
-       // a compressed entry.
-       if (entry.getMethod() == ZipEntry.DEFLATED && peekSig() == (int)EXTSIG) 
{
-
-         // Consume signature
-         readSig();
-
-         // Read remainder of data header
-         readFully(dheader, sigbuf.length, dheader.length - sigbuf.length);
-
-         // Read CRC
-         int data_crc = get32(dheader, EXTCRC);
-         entry.setCrc(data_crc & 0xffffffffL);
-
-         // Read compressed size
-         int data_csize = get32(dheader, EXTSIZ);
-         entry.setCompressedSize(data_csize & 0xffffffffL);
-
-         // Read uncompressed size
-         int data_size = get32(dheader, EXTLEN);
-         if (data_crc == 0 && data_size != 0) {
-             throw new IOException(
-               "CRC error: data_crc=0, data_csize=" + data_csize + 
",data_size=" + data_size);
-         }
-         entry.setSize(data_size & 0xffffffffL);
-
-         //System.out.println("ZipEntry (Post DATA): " + entry
-         // + ", meth=" + entry.method + ", size=" + entry.size
-         // + ", csize=" + entry.csize + ", crc=" + entry.crc);
-       }
-       
-       // Close the input stream for the rest of the world.
-       sinf.setLength(0);
-      } finally {
-       entry = null;
-      }
-    }
-  }
-
-  public int read(byte[] b, int off, int len) throws IOException {
-    return super.read(b, off, len);
-  }
-
-  public long skip(long n) throws IOException {
-    return super.skip(n);
-  }
-
-  public void close() throws IOException {
-    closeEntry();
-    super.close();
-    // Now completely close the byte stream. There may be some
-    // bytes left in the buffer.
-    sinf.setInput(null, 0, 0);
-  }
-
-  private int get16(byte[] buf, int base) {
-    int val = (int)buf[base] & 0xFF;
-    val |= ((int)buf[base+1] & 0xFF) << 8;
-    return (val);
-  }
-
-  private int get32(byte[] buf, int base) {
-    return  buf[base] & 0xFF
-       | ((buf[base+1] & 0xFF) << 8)
-       | ((buf[base+2] & 0xFF) << 16)
-       | ((buf[base+3] & 0xFF) << 24);
-  }
-
-  private void readFully(byte[] buf, int off, int len) throws IOException {
-    int nread;
-
-    for (int remain = len; remain > 0; remain -= nread) {
-      nread = read(buf, off, remain);
-      if (nread == -1) {
-       if (remain != 0) {
-         throw new IOException("truncated file (only read "
-           + (len - remain) + "/" + len + ")");
-       }
-       return;
-      }
-      off += nread;
-    }
-  }
-
-  private int readSig() throws IOException {
-    int sig = peekSig();
-    gotSig = false;
-    return sig;
-  }
-
-  private int peekSig() throws IOException {
-    if (!gotSig) {
-      readFully(sigbuf, 0, sigbuf.length);
-      gotSig = true;
-    }
-    return get32(sigbuf, 0);
-  }
-
-  protected ZipEntry createZipEntry(String name) {
-       return new ZipEntry(name);
-  }
-}
-
===================================================================
Checking out 
kaffe/libraries/javalib/vmspecific/java/util/zip/ZipOutputStream.java~
RCS:  
/home/cvs/kaffe/kaffe/libraries/javalib/vmspecific/java/util/zip/Attic/ZipOutputStream.java~,v
VERS: 1.1
***************
--- kaffe/libraries/javalib/vmspecific/java/util/zip/ZipOutputStream.java~      
Sat Dec  3 15:57:41 2005
+++ /dev/null   Sun Aug  4 19:57:58 2002
@@ -1,344 +0,0 @@
-/*
- * Java core library component.
- *
- * Copyright (c) 1997, 1998
- *      Transvirtual Technologies, Inc.  All rights reserved.
- *
- * See the file "license.terms" for information on usage and redistribution
- * of this file.
- */
-
-package java.util.zip;
-
-import java.io.IOException;
-import java.io.OutputStream;
-import java.io.UnsupportedEncodingException;
-import java.util.Enumeration;
-import java.util.Vector;
-
-import kaffe.util.UTF8;
-
-// Reference: ftp://ftp.uu.net/pub/archiving/zip/doc/appnote-970311-iz.zip
-
-public class ZipOutputStream extends DeflaterOutputStream
-       implements ZipConstants {
-
-  public static final int STORED = Deflater.NO_COMPRESSION;
-  public static final int DEFLATED = Deflater.DEFLATED;
-
-private static final int ZIPVER_1_0 = 0x000a;
-private static final int ZIPVER_2_0 = 0x0014;
-
-private int method = Deflater.DEFLATED;
-private int level = Deflater.DEFAULT_COMPRESSION;
-private ZipEntry curr;
-private Vector dir;
-private OutputStream strm;
-private int dout;
-private CRC32 crc;
-
-class Storer
-  extends Deflater {
-
-private int total;
-private byte[] buf;
-private int off;
-private int len;
-
-Storer() {
-    total = 0;
-    off = 0;
-    len = 0;
-}
-
-public int deflate(byte[] b, int p, int l) {
-       if (l >= len) {
-               l = len;
-       }
-       System.arraycopy(buf, off, b, p, l);
-       total += l;
-       off += l;
-       len -= l;
-       return (l);
-}
-
-public synchronized void setInput(byte b[], int o, int l)
-{
-       buf = b;
-       off = o;
-       len = l;
-}
-
-public boolean needsInput() {
-       return (len > 0 ? false : true);
-}
-
-public boolean finished() {
-       return (len > 0 ? false : true);
-}
-
-public int getTotalIn() {
-       return (total);
-}
-
-public int getTotalOut() {
-       return (total);
-}
-
-public void reset() {
-}
-
-}
-
-public ZipOutputStream(OutputStream out)
-{
-       super(out);
-       strm = out;
-       curr = null;
-       dir = new Vector();
-       dout = 0;
-       crc = new CRC32();
-}
-
-public void close() throws IOException
-{
-       finish();
-       super.close();
-}
-
-public void closeEntry() throws IOException
-{
-       if (curr == null) {
-               return;
-       }
-
-       super.finish();
-       int in = def.getTotalIn();
-       int out = def.getTotalOut();
-       long crcval = crc.getValue();
-       def.reset();
-       crc.reset();
-
-       if (curr.getCompressedSize() != -1 && curr.getCompressedSize() != out) {
-               throw new ZipException("compress size set incorrectly");
-       }
-       if (curr.getSize() != -1 && curr.getSize() != in) {
-               throw new ZipException("uncompress size set incorrectly");
-       }
-       if (curr.getCrc() != -1 && curr.getCrc() != crcval) {
-               throw new ZipException("crc set incorrectly");
-       }
-
-       curr.setCompressedSize(out);
-       curr.setSize(in);
-       curr.setCrc(crcval);
-
-       dout += curr.getCompressedSize();
-
-       // We only add the data descriptor when writing a compressed entry
-
-       if (curr.flag == 0x0008) {
-           byte[] da = new byte[EXTHDR];
-           put32(da, 0, (int)EXTSIG);
-           put32(da, EXTCRC, (int)curr.getCrc());
-           put32(da, EXTSIZ, (int) curr.getCompressedSize());
-           put32(da, EXTLEN, (int) curr.getSize());
-           strm.write(da);
-           dout += EXTHDR;
-       }
-
-       curr = null;
-}
-
-public void finish() throws IOException {
-       byte[] ch = new byte[CENHDR];
-       int count = 0;
-       int size = 0;
-
-       if (dir == null) {
-               return;
-       }
-
-       closeEntry();
-
-       // Write the central directory
-       for (Enumeration e = dir.elements(); e.hasMoreElements(); ) {
-               ZipEntry ze = (ZipEntry)e.nextElement();
-
-               // Convert name to UTF-8 binary
-               byte[] nameBuf = (ze.getName() != null) ?
-                   UTF8.encode(ze.getName()) : new byte[0];
-
-               // Write central directory entry
-               put32(ch, 0, (int)CENSIG);
-               int zipver = (ze.getMethod() == STORED ? ZIPVER_1_0 : 
ZIPVER_2_0);
-               put16(ch, CENVEM, zipver);
-               put16(ch, CENVER, zipver);
-               put16(ch, CENFLG, ze.flag);
-               put16(ch, CENHOW, ze.getMethod());
-               put32(ch, CENTIM, ze.dosTime);
-               put32(ch, CENCRC, (int)ze.getCrc());
-               put32(ch, CENSIZ, (int)ze.getCompressedSize());
-               put32(ch, CENLEN, (int)ze.getSize());
-               put16(ch, CENNAM, nameBuf.length);
-               put16(ch, CENEXT, ze.getExtra() == null ?
-                       0 : ze.getExtra().length);
-               put16(ch, CENCOM, ze.getComment() == null ?
-                       0 : ze.getComment().length());
-               put16(ch, CENDSK, 0);
-               put16(ch, CENATT, 0);
-               put32(ch, CENATX, 0);
-               put32(ch, CENOFF, (int)ze.offset);
-
-               strm.write(ch);
-               size += CENHDR;
-
-               // Write name
-               strm.write(nameBuf);
-               size += nameBuf.length;
-
-               // Write any extra stuff
-               if (ze.getExtra() != null) {
-                   strm.write(ze.getExtra());
-                   size += ze.getExtra().length;
-               }
-
-               count++;
-       }
-
-       // Flag error if no entries were written.
-       if (count == 0) {
-               throw new ZipException("ZIP file must have at least one entry");
-       }
-
-       byte[] ce = new byte[ENDHDR];
-       put32(ce, 0, (int)ENDSIG);
-       put16(ce, ENDNRD, 0);
-       put16(ce, ENDDCD, 0);
-       put16(ce, ENDSUB, count);
-       put16(ce, ENDTOT, count);
-       put32(ce, ENDSIZ, size);
-       put32(ce, ENDOFF, dout);
-       put16(ce, ENDCOM, 0);
-
-       strm.write(ce);
-
-       dir = null;
-}
-
-public void putNextEntry(ZipEntry ze) throws IOException
-{
-       closeEntry();   // Close previous entry
-
-       if (ze.getMethod() == -1) {
-               ze.setMethod(method);
-       }
-       if (ze.getMethod() == STORED) {
-               if (ze.getSize() == -1) {
-                       throw new ZipException("size not set in stored entry");
-               }
-               ze.setCompressedSize(ze.getSize());
-               if (ze.getCrc() == -1) {
-                       throw new ZipException("crc not set in stored entry");
-               }
-               ze.flag = 0;
-       } else {
-               ze.flag = 0x0008;
-       }
-
-       if (curr == null || curr.getMethod() != ze.getMethod()) {
-               if (ze.getMethod() == STORED) {
-                       def = new Storer();
-               }
-               else {
-                       def = new Deflater(level, true);
-               }
-       }
-
-       // Convert name to UTF-8 binary
-       byte[] nameBuf = (ze.getName() != null) ?
-           UTF8.encode(ze.getName()) : new byte[0];
-
-       byte[] lh = new byte[LOCHDR];
-       put32(lh, 0, (int)LOCSIG);
-       put16(lh, LOCVER,
-               ze.getMethod() == STORED ? ZIPVER_1_0 : ZIPVER_2_0);
-       put16(lh, LOCFLG, ze.flag);
-       put16(lh, LOCHOW, ze.getMethod());
-       put32(lh, LOCTIM, ze.dosTime);
-
-       if (ze.getMethod() == STORED) {
-               put32(lh, LOCCRC, (int)ze.getCrc());
-               put32(lh, LOCSIZ, (int)ze.getCompressedSize());
-               put32(lh, LOCLEN, (int)ze.getSize());
-       } else {
-               put32(lh, LOCCRC, 0);
-               put32(lh, LOCSIZ, 0);
-               put32(lh, LOCLEN, 0);
-       }
-
-       put16(lh, LOCNAM, nameBuf.length);
-       put16(lh, LOCEXT, ze.getExtra() == null ? 0 : ze.getExtra().length);
-
-       strm.write(lh);
-
-       ze.offset = dout;
-       dout += LOCHDR;
-
-       // Write name
-       strm.write(nameBuf);
-       dout += nameBuf.length;
-
-       // Write any extra stuff
-       if (ze.getExtra() != null) {
-               strm.write(ze.getExtra());
-               dout += ze.getExtra().length;
-       }
-
-       // Add entry to list of entries we need to write at the end.
-       dir.addElement(ze);
-
-       curr = ze;

*** Patch too long, truncated ***

_______________________________________________
kaffe mailing list
[email protected]
http://kaffe.org/cgi-bin/mailman/listinfo/kaffe

Reply via email to