some small patches

Aaron Place beavis at ihug.co.nz
Sun Apr 18 16:07:41 PDT 1999


Could someone please commit these changes (if they are correct).

	* libraries/clib/io/RandomAccessFile.c,
 	libraries/javalib/java/io/RandomAccessFile.java: change
 	constructor to throw FileNotFoundException
	* libraries/javalib/java/io/ObjectStreamClass.java,
 	ObjectStreamConstants.java, kaffe/io/ObjectStreamClassImpl.java:
 	replace SC_WRRD_METHODS with SC_WRITE_METHOD and add jdk1.2
 	constants
	* libraries/javalib/java/io/PipedInputStream.java: rename pipe to
 	buffer and make protected and fix EOS bug (now passes mauve test)
	(available): new method
	* libraries/javalib/java/io/PrintWriter.java: rename strm to
	out and make protected
	* libraries/javalib/java/io/StringReader.java (ready): fix
	* libraries/javalib/java/io/StringWriter.java (StringWriter): make 
	public
	(close): change signature
	* libraries/javalib/java/lang/Long.java (parseLong): should throw
 	NumberFormatException
	* libraries/javalib/java/lang/Math.java (toDegrees): new method
 	(toRadians): new method
	* libraries/javalib/java/lang/reflect/Modifier.java: add strictfp
 	modifier
	* libraries/javalib/java/net/SocketOptions.java: make public
	* libraries/javalib/java/text/ChoiceFormat.java (parse): fix
	* libraries/javalib/java/text/DateFormat.java, NumberFormat.java:
 	clone is handled by superclass
	* libraries/javalib/java/util/AbstractCollection.java,
 	AbstractList.java: make constructor protected
	* libraries/javalib/java/util/zip/Deflater.java (setStrategy): change
 	signature
	* libraries/javalib/java/util/zip/GZIPInputStream.java: make most
 	constants default access
	* libraries/javalib/java/util/zip/Inflater.java (init): make private
	* libraries/javalib/java/util/zip/ZipEntry.java: make Cloneable

Aaron.
-------------- next part --------------
Index: libraries/clib/io/RandomAccessFile.c
===================================================================
RCS file: /home/cvspublic/kaffe/libraries/clib/io/RandomAccessFile.c,v
retrieving revision 1.8
diff -u -r1.8 RandomAccessFile.c
--- RandomAccessFile.c	1999/04/06 23:33:23	1.8
+++ RandomAccessFile.c	1999/04/11 04:10:42
@@ -37,7 +37,7 @@
 	rc = KOPEN(str, (rw == 0 ? O_RDONLY : O_RDWR|O_CREAT)|O_BINARY, 0666, &fd);
 	if (rc) {
 		unhand(unhand(this)->fd)->fd = -1;
-		SignalError("java.io.IOException", SYS_ERROR(rc));
+		SignalError("java.io.FileNotFoundException", SYS_ERROR(rc));
 	}
 	unhand(unhand(this)->fd)->fd = fd;
 }
Index: libraries/javalib/java/io/InputStream.java
===================================================================
RCS file: /home/cvspublic/kaffe/libraries/javalib/java/io/InputStream.java,v
retrieving revision 1.3
diff -u -r1.3 InputStream.java
--- InputStream.java	1998/12/08 02:05:06	1.3
+++ InputStream.java	1999/04/11 04:10:45
@@ -42,7 +42,7 @@
 		for (int pos=off; pos<off+len; pos++) {
 			int data=read();
 			if (data==-1) {
-				if (pos-off==0) return -1; else return pos-off;
+				return (pos-off==0 ? -1 : pos-off);
 			}
 			b[pos]=(byte )data;
 		}
Index: libraries/javalib/java/io/ObjectStreamClass.java
===================================================================
RCS file: /home/cvspublic/kaffe/libraries/javalib/java/io/ObjectStreamClass.java,v
retrieving revision 1.6
diff -u -r1.6 ObjectStreamClass.java
--- ObjectStreamClass.java	1999/03/24 01:14:44	1.6
+++ ObjectStreamClass.java	1999/04/11 04:10:48
@@ -29,7 +29,8 @@
 private static final long serialVersionUID = -6120832682080437368L;
 
 public static SerializationFactory factory = new DefaultSerializationFactory();
-
+//public static final ObjectStreamField[] NO_FIELDS = {};
+    
 private static Hashtable streamClasses = new Hashtable();
 
 protected String name;
@@ -72,7 +73,7 @@
 	else if (Serializable.class.isAssignableFrom(cl)) {
 		method = ObjectStreamConstants.SC_SERIALIZABLE;
 		if (factory.hasRdWrMethods(cl)) {
-			method |= ObjectStreamConstants.SC_WRRD_METHODS;
+			method |= ObjectStreamConstants.SC_WRITE_METHOD;
 //System.out.println(" has read/write");
                 }
 //System.out.println(" is serializable");
Index: libraries/javalib/java/io/ObjectStreamConstants.java
===================================================================
RCS file: /home/cvspublic/kaffe/libraries/javalib/java/io/ObjectStreamConstants.java,v
retrieving revision 1.2
diff -u -r1.2 ObjectStreamConstants.java
--- ObjectStreamConstants.java	1999/02/10 05:01:37	1.2
+++ ObjectStreamConstants.java	1999/04/11 04:10:49
@@ -15,6 +15,10 @@
 public final static short STREAM_MAGIC = (short)0xaced;
 public final static short STREAM_VERSION = 5;
 
+public final static int PROTOCOL_VERSION_1 = 0x1;
+public final static int PROTOCOL_VERSION_2 = 0x2;
+
+public final static byte TC_BASE = (byte)0x70;
 public final static byte TC_NULL = (byte)0x70;
 public final static byte TC_REFERENCE = (byte)0x71;
 public final static byte TC_CLASSDESC = (byte)0x72;
@@ -27,10 +31,17 @@
 public final static byte TC_RESET = (byte)0x79;
 public final static byte TC_BLOCKDATALONG = (byte)0x7A;
 public final static byte TC_EXCEPTION = (byte)0x7B;
+public final static byte TC_MAX = (byte)0x7B;
 
-public final static byte SC_WRRD_METHODS = (byte)0x01;
+public final static byte SC_WRITE_METHOD = (byte)0x01;
+//public final static byte SC_WRRD_METHODS = (byte)0x01;
 public final static byte SC_SERIALIZABLE = (byte)0x02;
 public final static byte SC_EXTERNALIZABLE = (byte)0x04;
-public final static byte SC_STRING = (byte)0x08;
+public final static byte SC_BLOCK_DATA = (byte)0x08;
+//public final static byte SC_STRING = (byte)0x08;
+
+public final static int baseWireHandle = 0x7E0000; 
+//public final static SerializablePermission SUBCLASS_IMPLEMENTATION_PERMISSION = ???;
+//public final static SerializablePermission SUBSTITUTION_PERMISSION = ???;
 
 }
Index: libraries/javalib/java/io/PipedInputStream.java
===================================================================
RCS file: /home/cvspublic/kaffe/libraries/javalib/java/io/PipedInputStream.java,v
retrieving revision 1.5
diff -u -r1.5 PipedInputStream.java
--- PipedInputStream.java	1999/03/23 21:27:17	1.5
+++ PipedInputStream.java	1999/04/11 04:10:49
@@ -19,10 +19,11 @@
 {
 	PipedOutputStream src = null;
 	final protected static int PIPE_SIZE = 512;
-	protected byte[] pipe = new byte[PIPE_SIZE];
+	protected byte[] buffer = new byte[PIPE_SIZE];
 	protected int out = 0;
 	protected int in = 0;
 	private boolean closed = true;
+        private boolean finished = true;
 
 public PipedInputStream () {
 }
@@ -32,6 +33,10 @@
 	connect(src);
 }
 
+public int available() throws IOException {
+	return(in >= out ? in-out : PIPE_SIZE+out-in);
+}
+    
 public void close() throws IOException {
 	out = 0;
 	in = 0;
@@ -47,6 +52,7 @@
 		src.connect(this);
 	}
 	closed = false;
+	finished = false;
 }
 
 public synchronized int read() throws IOException {
@@ -55,19 +61,23 @@
 		throw new IOException("stream closed");
 	}
 
+	if (finished && (out == in)) {
+	        return (-1);
+	}
+
 	while (out == in) {
 		try {
 			this.wait();
 		}
 		catch (InterruptedException e) {
 		}
-		if (closed) {
-			return (-1);
+		if (finished && (out == in)) {
+		        return (-1);
 		}
 	}
 
 	/* Should be Ok now */
-	byte result = pipe[out];
+	byte result = buffer[out];
 	out = (out + 1) % PIPE_SIZE;
 
 	this.notifyAll();
@@ -80,13 +90,13 @@
 }
 
 protected synchronized void receive(int b) throws IOException {
-	while (out == in+1) {
+	while (out == (in+1) % PIPE_SIZE) {
 		try {
 			this.wait();
 		}
 		catch (InterruptedException e) {}
 	}
-	pipe[in] = (byte)b;
+	buffer[in] = (byte)b;
 	in = (in + 1) % PIPE_SIZE;
 
 	this.notifyAll();
@@ -94,6 +104,6 @@
 
 //Used in java.io.PipedOutputStream
 void receivedLast() {
-	closed = true;
+    	finished = true;
 }
 }
Index: libraries/javalib/java/io/PrintWriter.java
===================================================================
RCS file: /home/cvspublic/kaffe/libraries/javalib/java/io/PrintWriter.java,v
retrieving revision 1.3
diff -u -r1.3 PrintWriter.java
--- PrintWriter.java	1998/12/09 23:20:12	1.3
+++ PrintWriter.java	1999/04/11 04:10:50
@@ -16,7 +16,7 @@
 
   private static final String newline = System.getProperty("line.separator");
 
-  private Writer strm;
+  protected Writer out;
   private boolean flsh;
   private boolean error;
 
@@ -27,7 +27,7 @@
 
   public PrintWriter(Writer out, boolean autoFlush)
   {
-    strm = out;
+    this.out = out;
     flsh = autoFlush;
     error = false;
   }
@@ -39,7 +39,7 @@
 
   public PrintWriter(OutputStream out, boolean autoFlush)
   {
-    strm = new OutputStreamWriter(out);
+    this.out = new OutputStreamWriter(out);
     flsh = autoFlush;
     error = false;
   }
@@ -47,7 +47,7 @@
   public void flush()
   {
     try {
-      strm.flush();
+      out.flush();
     }
     catch (IOException _) {
       error = true;
@@ -57,7 +57,7 @@
   public void close()
   {
     try {
-      strm.close();
+      out.close();
     }
     catch (IOException _) {
       error = true;
@@ -85,7 +85,7 @@
   public void write(char buf[], int off, int len)
   {
     try {
-      strm.write(buf, off, len);
+      out.write(buf, off, len);
     }
     catch (IOException _) {
       error = true;
Index: libraries/javalib/java/io/RandomAccessFile.java
===================================================================
RCS file: /home/cvspublic/kaffe/libraries/javalib/java/io/RandomAccessFile.java,v
retrieving revision 1.9
diff -u -r1.9 RandomAccessFile.java
--- RandomAccessFile.java	1999/04/05 03:36:08	1.9
+++ RandomAccessFile.java	1999/04/11 04:10:50
@@ -25,7 +25,7 @@
 	this(file.getPath(), mode);
 }
 
-public RandomAccessFile(String name, String mode) throws IOException {
+public RandomAccessFile(String name, String mode) throws FileNotFoundException {
 	boolean writable;
 	if (mode.equalsIgnoreCase("r")) writable=false;
 	else if (mode.equalsIgnoreCase("rw")) writable=true;
Index: libraries/javalib/java/io/StringReader.java
===================================================================
RCS file: /home/cvspublic/kaffe/libraries/javalib/java/io/StringReader.java,v
retrieving revision 1.2
diff -u -r1.2 StringReader.java
--- StringReader.java	1998/12/09 23:20:13	1.2
+++ StringReader.java	1999/04/11 04:10:50
@@ -17,17 +17,19 @@
 	private char[] buf;
 	private int pos;
 	private int markpos;
+	private boolean closed;
 
 public StringReader(String s)
 	{
 	buf = s.toCharArray();
 	pos = 0;
 	markpos = 0;
+	closed = false;
 }
 
 public void close()
 	{
-	// Does nothing.
+	closed = false;
 }
 
 public void mark(int readAheadLimit) throws IOException
@@ -65,8 +67,10 @@
 	}
 }
 
-public boolean ready()
+public boolean ready() throws IOException
 	{
+	if(closed)
+	        throw new IOException("Stream closed");
 	return (true);
 }
 
Index: libraries/javalib/java/io/StringWriter.java
===================================================================
RCS file: /home/cvspublic/kaffe/libraries/javalib/java/io/StringWriter.java,v
retrieving revision 1.2
diff -u -r1.2 StringWriter.java
--- StringWriter.java	1998/12/09 23:20:13	1.2
+++ StringWriter.java	1999/04/11 04:10:50
@@ -22,7 +22,7 @@
     this(DEFAULT);
   }
 
-  protected StringWriter(int initialSize)
+  public StringWriter(int initialSize)
   {
     buf = new StringBuffer(initialSize);
   }
@@ -62,7 +62,7 @@
     // Does nothing.
   }
 
-  public void close()
+  public void close() throws IOException
   {
     // Does nothing.
   }
Index: libraries/javalib/java/lang/Long.java
===================================================================
RCS file: /home/cvspublic/kaffe/libraries/javalib/java/lang/Long.java,v
retrieving revision 1.13
diff -u -r1.13 Long.java
--- Long.java	1999/03/23 21:59:28	1.13
+++ Long.java	1999/04/11 04:10:50
@@ -101,7 +101,7 @@
 	return parseLong(s, 10);
 }
 
-public static long parseLong(String s, int radix) {
+public static long parseLong(String s, int radix) throws NumberFormatException {
 	if (s.length() <= 0) {
 		throw new NumberFormatException();
 	}
Index: libraries/javalib/java/lang/Math.java
===================================================================
RCS file: /home/cvspublic/kaffe/libraries/javalib/java/lang/Math.java,v
retrieving revision 1.6
diff -u -r1.6 Math.java
--- Math.java	1999/03/10 08:31:30	1.6
+++ Math.java	1999/04/11 04:10:50
@@ -100,4 +100,13 @@
 native public static double sqrt(double a);
 
 native public static double tan(double a);
+
+public static double toDegrees(double angrad) {
+	return(angrad * 180 / PI);
+}
+
+public static double toRadians(double angdeg) {
+	return(angdeg * PI / 180);
+}
+
 }
Index: libraries/javalib/java/lang/reflect/Modifier.java
===================================================================
RCS file: /home/cvspublic/kaffe/libraries/javalib/java/lang/reflect/Modifier.java,v
retrieving revision 1.3
diff -u -r1.3 Modifier.java
--- Modifier.java	1998/12/13 05:32:22	1.3
+++ Modifier.java	1999/04/11 04:10:51
@@ -23,6 +23,7 @@
   public static final int NATIVE = 0x0100;
   public static final int INTERFACE = 0x0200;
   public static final int ABSTRACT = 0x0400;
+  public static final int STRICT = 0x0800;
 
   public Modifier()
   {
@@ -84,6 +85,11 @@
     return ((mod & ABSTRACT) == 0 ? false : true);
   }
 
+  public static boolean isStrict(int mod)
+  {
+    return ((mod & STRICT) == 0 ? false : true);
+  }
+
   public static String toString(int mod)
   {
     StringBuffer str = new StringBuffer();
@@ -117,6 +123,9 @@
     }
     if ((mod & NATIVE) != 0) {
       append(str, "native");
+    }
+    if ((mod & STRICT) != 0) {
+      append(str, "strictfp");
     }
     if ((mod & INTERFACE) != 0) {
       append(str, "interface");
Index: libraries/javalib/java/net/SocketOptions.java
===================================================================
RCS file: /home/cvspublic/kaffe/libraries/javalib/java/net/SocketOptions.java,v
retrieving revision 1.6
diff -u -r1.6 SocketOptions.java
--- SocketOptions.java	1999/03/10 08:31:31	1.6
+++ SocketOptions.java	1999/04/11 04:10:51
@@ -10,7 +10,7 @@
 
 package java.net;
 
-interface SocketOptions {
+public interface SocketOptions {
 
 /*
  * Various options.  Note that these constants match those used by Sun.
Index: libraries/javalib/java/text/ChoiceFormat.java
===================================================================
RCS file: /home/cvspublic/kaffe/libraries/javalib/java/text/ChoiceFormat.java,v
retrieving revision 1.6
diff -u -r1.6 ChoiceFormat.java
--- ChoiceFormat.java	1999/03/23 21:27:20	1.6
+++ ChoiceFormat.java	1999/04/11 04:10:52
@@ -171,7 +171,7 @@
 	}
 
 	Double number;
-	while(stopIndex < str.length()){
+	while(stopIndex <= str.length()){
 	    number = (Double)patternNames.get(str.substring(startIndex,stopIndex));
 	    if(number == null)
 		stopIndex++;
Index: libraries/javalib/java/text/DateFormat.java
===================================================================
RCS file: /home/cvspublic/kaffe/libraries/javalib/java/text/DateFormat.java,v
retrieving revision 1.5
diff -u -r1.5 DateFormat.java
--- DateFormat.java	1999/03/24 01:14:48	1.5
+++ DateFormat.java	1999/04/11 04:10:56
@@ -17,7 +17,7 @@
 import java.util.ResourceBundle;
 import java.util.Calendar;
 
-public abstract class DateFormat extends Format implements Cloneable {
+public abstract class DateFormat extends Format {
 
 private static final long serialVersionUID = 7218322306649953788L;
 public final static int FULL = 0;
@@ -51,10 +51,6 @@
 private boolean lenient = true;
 
 protected DateFormat() {
-}
-
-public Object clone() {
-	return (super.clone());
 }
 
 public boolean equals(Object obj) {
Index: libraries/javalib/java/text/NumberFormat.java
===================================================================
RCS file: /home/cvspublic/kaffe/libraries/javalib/java/text/NumberFormat.java,v
retrieving revision 1.8
diff -u -r1.8 NumberFormat.java
--- NumberFormat.java	1999/03/24 01:14:48	1.8
+++ NumberFormat.java	1999/04/11 04:10:56
@@ -15,7 +15,6 @@
  */
 abstract public class NumberFormat
   extends Format
-  implements Cloneable
 {
 	private static final long serialVersionUID = -2308460125733713944L;
 	final public static int INTEGER_FIELD = 0;
@@ -34,10 +33,6 @@
 	maxint = 0;
 	minfrac = 0;
 	minint = 1;
-}
-
-public Object clone() {
-	return (super.clone());
 }
 
 public boolean equals(Object obj) {
Index: libraries/javalib/java/util/AbstractCollection.java
===================================================================
RCS file: /home/cvspublic/kaffe/libraries/javalib/java/util/AbstractCollection.java,v
retrieving revision 1.2
diff -u -r1.2 AbstractCollection.java
--- AbstractCollection.java	1998/12/09 23:20:29	1.2
+++ AbstractCollection.java	1999/04/11 04:10:56
@@ -14,7 +14,7 @@
 
 public abstract class AbstractCollection implements Collection {
 
-public AbstractCollection() {
+protected AbstractCollection() {
 }
 
 public abstract Iterator iterator();
Index: libraries/javalib/java/util/AbstractList.java
===================================================================
RCS file: /home/cvspublic/kaffe/libraries/javalib/java/util/AbstractList.java,v
retrieving revision 1.2
diff -u -r1.2 AbstractList.java
--- AbstractList.java	1999/04/06 19:10:54	1.2
+++ AbstractList.java	1999/04/11 04:10:56
@@ -15,6 +15,9 @@
 
 protected int modCount;
 
+protected AbstractList() {
+}
+    
 public boolean add(Object o) {
   add(size(), o);
   return (true);
Index: libraries/javalib/java/util/zip/Deflater.java
===================================================================
RCS file: /home/cvspublic/kaffe/libraries/javalib/java/util/zip/Deflater.java,v
retrieving revision 1.1
diff -u -r1.1 Deflater.java
--- Deflater.java	1998/07/14 17:02:11	1.1
+++ Deflater.java	1999/04/11 04:10:56
@@ -75,7 +75,7 @@
     setDictionary(b, 0, b.length);
   }
 
-  public synchronized void setStrategy(int stgy) throws IllegalArgumentException
+  public synchronized void setStrategy(int stgy)
   {
     if (stgy != DEFLATED) {
       throw new IllegalArgumentException("only support deflation");
Index: libraries/javalib/java/util/zip/GZIPInputStream.java
===================================================================
RCS file: /home/cvspublic/kaffe/libraries/javalib/java/util/zip/GZIPInputStream.java,v
retrieving revision 1.4
diff -u -r1.4 GZIPInputStream.java
--- GZIPInputStream.java	1999/01/29 00:07:20	1.4
+++ GZIPInputStream.java	1999/04/11 04:10:56
@@ -20,16 +20,16 @@
 private InputStream strm;
 
 public static final int GZIP_MAGIC		= 0x1f8b;
-public static final int OLD_GZIP_MAGIC		= 0x1f9e;
+static final int OLD_GZIP_MAGIC		= 0x1f9e;
 
-public static final int GZIP_FLAG_ASCII_FLAG	= 0x01;	// probably ascii text
-public static final int GZIP_FLAG_CONTINUATION	= 0x02;	// continuation of
+static final int GZIP_FLAG_ASCII_FLAG	= 0x01;	// probably ascii text
+static final int GZIP_FLAG_CONTINUATION	= 0x02;	// continuation of
 							//  multi-part gzip file
-public static final int GZIP_FLAG_EXTRA_FIELD	= 0x04;	// extra field present
-public static final int GZIP_FLAG_ORIG_NAME	= 0x08;	// file name present
-public static final int GZIP_FLAG_COMMENT	= 0x10;	// file comment present
-public static final int GZIP_FLAG_ENCRYPTED	= 0x20;	// file is encrypted
-public static final int GZIP_FLAG_RESERVED	= 0xc0;	// must be zero
+static final int GZIP_FLAG_EXTRA_FIELD	= 0x04;	// extra field present
+static final int GZIP_FLAG_ORIG_NAME	= 0x08;	// file name present
+static final int GZIP_FLAG_COMMENT	= 0x10;	// file comment present
+static final int GZIP_FLAG_ENCRYPTED	= 0x20;	// file is encrypted
+static final int GZIP_FLAG_RESERVED	= 0xc0;	// must be zero
 
 public GZIPInputStream(InputStream in) throws IOException {
 	this(in, 512);
Index: libraries/javalib/java/util/zip/Inflater.java
===================================================================
RCS file: /home/cvspublic/kaffe/libraries/javalib/java/util/zip/Inflater.java,v
retrieving revision 1.2
diff -u -r1.2 Inflater.java
--- Inflater.java	1999/02/10 21:34:52	1.2
+++ Inflater.java	1999/04/11 04:10:56
@@ -101,7 +101,7 @@
   public native synchronized int getTotalIn();
   public native synchronized int getTotalOut();
   public native synchronized void reset();
-  public native synchronized void init(boolean nowrap);
+  private native synchronized void init(boolean nowrap);
   public native synchronized void end();
 
 }
Index: libraries/javalib/java/util/zip/ZipEntry.java
===================================================================
RCS file: /home/cvspublic/kaffe/libraries/javalib/java/util/zip/ZipEntry.java,v
retrieving revision 1.6
diff -u -r1.6 ZipEntry.java
--- ZipEntry.java	1999/02/16 19:44:19	1.6
+++ ZipEntry.java	1999/04/11 04:10:56
@@ -10,7 +10,7 @@
 
 package java.util.zip;
 
-public class ZipEntry implements ZipConstants {
+public class ZipEntry implements Cloneable, ZipConstants {
 
   public static final int STORED = Deflater.NO_COMPRESSION;
   public static final int DEFLATED = Deflater.DEFLATED;
Index: libraries/javalib/java/util/zip/ZipFile.java
===================================================================
RCS file: /home/cvspublic/kaffe/libraries/javalib/java/util/zip/ZipFile.java,v
retrieving revision 1.2
diff -u -r1.2 ZipFile.java
--- ZipFile.java	1998/09/30 23:20:23	1.2
+++ ZipFile.java	1999/04/11 04:10:56
@@ -28,7 +28,7 @@
 	name = fname;
 	zip = openZipFile0(fname);
 	if (zip == null) {
-		throw new IOException("No such zip file" + fname);
+		throw new IOException("No such zip file " + fname);
 	}
 }
 
Index: libraries/javalib/kaffe/io/ObjectStreamClassImpl.java
===================================================================
RCS file: /home/cvspublic/kaffe/libraries/javalib/kaffe/io/ObjectStreamClassImpl.java,v
retrieving revision 1.6
diff -u -r1.6 ObjectStreamClassImpl.java
--- ObjectStreamClassImpl.java	1999/04/06 20:37:02	1.6
+++ ObjectStreamClassImpl.java	1999/04/11 04:10:58
@@ -50,7 +50,7 @@
 public ObjectStreamClassImpl() {
 	clazz = ObjectStreamClassImpl.class;
 	name = clazz.getName();
-	method = ObjectStreamConstants.SC_WRRD_METHODS|ObjectStreamConstants.SC_SERIALIZABLE;
+	method = ObjectStreamConstants.SC_WRITE_METHOD|ObjectStreamConstants.SC_SERIALIZABLE;
 	serialVersionUID = 0;
 	superstream = null;
 	iclazz = null;
@@ -76,7 +76,7 @@
  {
                         ((Externalizable)obj).readExternal(in);
                 }
-                else if ((method & ObjectStreamConstants.SC_WRRD_METHODS) !=
+                else if ((method & ObjectStreamConstants.SC_WRITE_METHOD) !=
  0) {
 			boolean restore = impl.enableBuffering(true);
                         invokeObjectReader0(obj, in);
@@ -225,7 +225,7 @@
 //System.out.println("...writeExternal");
 		((Externalizable)obj).writeExternal(out);
 	}
-	else if ((method & ObjectStreamConstants.SC_WRRD_METHODS) != 0) {
+	else if ((method & ObjectStreamConstants.SC_WRITE_METHOD) != 0) {
 //System.out.println("...invokeObjectWriter");
 		boolean restore = impl.enableBuffering(true);
 		invokeObjectWriter0(obj, out);


More information about the kaffe mailing list