bug in java/util/Vector

Archie Cobbs archie at whistle.com
Mon Jul 20 18:56:37 PDT 1998


This fixes a bug in class java/util/Vector:

Index: libraries/javalib/java/util/Vector.java
===================================================================
RCS file: /cvs/mod/net/kaffe/libraries/javalib/java/util/Vector.java,v
retrieving revision 1.1.1.1
diff -c -r1.1.1.1 Vector.java
*** Vector.java	1998/07/14 16:49:43	1.1.1.1
--- Vector.java	1998/07/21 01:53:54
***************
*** 82,87 ****
--- 82,89 ----
  }
  
  final public synchronized Object elementAt ( int index ) {
+ 	if ( index >= elementCount )
+ 		throw new ArrayIndexOutOfBoundsException();
  	return elementData[index];
  }
  

Thanks,
-Archie

___________________________________________________________________________
Archie Cobbs   *   Whistle Communications, Inc.  *   http://www.whistle.com


More information about the kaffe mailing list