mas 02/02/21 05:46:25 Modified: collections/src/java/org/apache/commons/collections SequencedHashMap.java Log: Fix a NullPointerException when an object passed to an entrySet method is not mapping found in the map. Exhibited with entrySet().remove(Object) and entrySet().contains(Object) Revision Changes Path 1.4 +4 -4 jakarta-commons/collections/src/java/org/apache/commons/collections/SequencedHashMap.java Index: SequencedHashMap.java =================================================================== RCS file: /home/cvs/jakarta-commons/collections/src/java/org/apache/commons/collections/SequencedHashMap.java,v retrieving revision 1.3 retrieving revision 1.4 diff -u -r1.3 -r1.4 --- SequencedHashMap.java 18 Feb 2002 20:34:57 -0000 1.3 +++ SequencedHashMap.java 21 Feb 2002 13:46:25 -0000 1.4 @@ -1,7 +1,7 @@ /* - * $Header: /home/cvs/jakarta-commons/collections/src/java/org/apache/commons/collections/SequencedHashMap.java,v 1.3 2002/02/18 20:34:57 morgand Exp $ - * $Revision: 1.3 $ - * $Date: 2002/02/18 20:34:57 $ + * $Header: /home/cvs/jakarta-commons/collections/src/java/org/apache/commons/collections/SequencedHashMap.java,v 1.4 2002/02/21 13:46:25 mas Exp $ + * $Revision: 1.4 $ + * $Date: 2002/02/21 13:46:25 $ * * ==================================================================== * @@ -587,7 +587,7 @@ Map.Entry e = (Map.Entry)o; Entry entry = (Entry)entries.get(e.getKey()); - if(entry.equals(e)) return entry; + if(entry != null && entry.equals(e)) return entry; else return null; }
-- To unsubscribe, e-mail: <mailto:[EMAIL PROTECTED]> For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>