-
Bug
-
Resolution: Fixed
-
P4
-
1.1.3, 1.3.0
-
rc1
-
generic, sparc
-
generic, solaris_2.5
-
Verified
Current specification for some constructors and methods doesn't describe the behaviour for null input, but the current implementation does throw NullPointerExcepion. This problem happens on the following constructor and methods: LinkedList(Collection c), addAll(Collection c), addAll(int index, Collection c).
For example, when I set null to Collection for those Constructor and methods, I got NullPointerException when the constructor or methods got invoked.
Name: krC82822 Date: 01/17/2001
17 Jan 2001, eval1127@eng -- see also #4378421
----------------
java version "1.3.0"
Java(TM) 2 Runtime Environment, Standard Edition (build 1.3.0-C)
Java HotSpot(TM) Client VM (build 1.3.0-C, mixed mode)
java.util.ArrayList.addAll(Collection c) assumes that the collection passed in
is not null. If it is null, a NullPointerException will be thrown.
The documentation does not make it clear whether or not it is reasonable to
pass null into this method.
(Review ID: 115293)
======================================================================
For example, when I set null to Collection for those Constructor and methods, I got NullPointerException when the constructor or methods got invoked.
Name: krC82822 Date: 01/17/2001
17 Jan 2001, eval1127@eng -- see also #4378421
----------------
java version "1.3.0"
Java(TM) 2 Runtime Environment, Standard Edition (build 1.3.0-C)
Java HotSpot(TM) Client VM (build 1.3.0-C, mixed mode)
java.util.ArrayList.addAll(Collection c) assumes that the collection passed in
is not null. If it is null, a NullPointerException will be thrown.
The documentation does not make it clear whether or not it is reasonable to
pass null into this method.
(Review ID: 115293)
======================================================================