-
Bug
-
Resolution: Fixed
-
P4
-
1.2.2
-
beta
-
generic
-
generic
Name: skT88420 Date: 11/02/99
java version "1.2.2"
Classic VM (build JDK-1.2.2-W, native threads, symcjit)
JComboBox's DefaultKeySelectionManager assumes that all values in the
ComboBoxModel are not nulls. In many places, it does:
<pre><code>
v = aModel.getElementAt(i).toString().toLowerCase();
</code></pre>
If the value at getElement(i) is null, this fails with a NullPointerException.
The proper code should probably be:
<pre><code>
v = String.valueOf(aModel.getElementAt(i)).toLowerCase();
</code></pre>
(Review ID: 97299)
======================================================================