--- a/jdk/src/share/classes/java/util/IdentityHashMap.java Sat May 10 11:49:25 2008 -0700
+++ b/jdk/src/share/classes/java/util/IdentityHashMap.java Sat May 10 12:14:53 2008 -0700
@@ -188,7 +188,6 @@
/**
* Use NULL_KEY for key if it is null.
*/
-
private static Object maskNull(Object key) {
return (key == null ? NULL_KEY : key);
}
@@ -378,8 +377,8 @@
*/
public boolean containsValue(Object value) {
Object[] tab = table;
- for (int i = 1; i < tab.length; i+= 2)
- if (tab[i] == value)
+ for (int i = 1; i < tab.length; i += 2)
+ if (tab[i] == value && tab[i - 1] != null)
return true;
return false;
@@ -905,7 +904,6 @@
* view the first time this view is requested. The view is stateless,
* so there's no reason to create more than one.
*/
-
private transient Set<Map.Entry<K,V>> entrySet = null;
/**