7174736: JCK test api/java_util/HashMap/index_EntrySet failing
Summary: Corrects a problem with HashMap.removeEntry() that caused a JCK test to fail
Reviewed-by: mduigou
Contributed-by: alan.bateman@oracle.com
--- a/jdk/src/share/classes/java/util/HashMap.java Thu Jun 07 18:42:47 2012 +0100
+++ b/jdk/src/share/classes/java/util/HashMap.java Thu Jun 07 01:01:09 2012 -0700
@@ -611,7 +611,7 @@
Map.Entry<?,?> entry = (Map.Entry<?,?>) o;
Object key = entry.getKey();
- int hash = (key == null) ? 0 : hash(key.hashCode());
+ int hash = (key == null) ? 0 : hash(key);
int i = indexFor(hash, table.length);
@SuppressWarnings("unchecked")
Entry<K,V> prev = (Entry<K,V>)table[i];