Commit 0db58ea4 by Tom Tromey Committed by Tom Tromey

re PR libgcj/4728 (java.util.zip.GZIPOutputStream.write(int) doesn't update CRC)

	* java/util/zip/GZIPOutputStream.java (write(int)): New method.
	Fixes PR libgcj/4728.

From-SVN: r46618
parent 54ee9799
2001-10-29 Tom Tromey <tromey@redhat.com>
* java/util/zip/GZIPOutputStream.java (write(int)): New method.
Fixes PR libgcj/4728.
2001-10-27 Tom Tromey <tromey@redhat.com>
* include/jni.h (struct JNINativeInterface) [GetStringLength]:
......
/* GZIPOutputStream.java - Create a file in gzip format
Copyright (C) 1999, 2000 Free Software Foundation, Inc.
Copyright (C) 1999, 2000, 2001 Free Software Foundation, Inc.
This file is part of GNU Classpath.
......@@ -78,6 +78,12 @@ public class GZIPOutputStream extends DeflaterOutputStream
crc = new CRC32 ();
}
public synchronized void write (int bval) throws IOException
{
super.write (bval);
crc.update (bval);
}
public synchronized void write (byte[] buf) throws IOException
{
write (buf, 0, buf.length);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment