JDK-7180621 : fix broken threshold value in 7180240
Type:Bug
Component:core-libs
Sub-Component:java.util
Affected Version:7u6
Priority:P2
Status:Closed
Resolution:Fixed
OS:generic
CPU:generic
Submitted:2012-06-28
Updated:2013-06-26
Resolved:2012-07-23
The Version table provides details related to the release that this issue/RFE will be addressed.
Unresolved : Release in which this issue/RFE will be addressed. Resolved: Release in which this issue/RFE has been resolved. Fixed : Release in which this issue/RFE has been fixed. The release containing this fix may be available for download as an Early Access Release or a General Availability Release.
SUGGESTED FIX
Sent to reviewers email.
diff --git a/src/share/classes/java/util/Hashtable.java b/src/share/classes/java/util/Hashtable.java
--- a/src/share/classes/java/util/Hashtable.java
+++ b/src/share/classes/java/util/Hashtable.java
@@ -167,13 +167,13 @@
* The default threshold of map capacity above which alternative hashing is
* used for String keys. Alternative hashing reduces the incidence of
* collisions due to weak hash code calculation for String keys.
- * <p/>
+ * <p>
* This value may be overridden by defining the system property
* {@code jdk.map.althashing.threshold}. A property value of {@code 1}
* forces alternative hashing to be used at all times whereas
* {@code -1} value ensures that alternative hashing is never used.
*/
- static final int ALTERNATIVE_HASHING_THRESHOLD_DEFAULT = 512;
+ static final int ALTERNATIVE_HASHING_THRESHOLD_DEFAULT = Integer.MAX_VALUE;
/**
* holds values which can't be initialized until after VM is booted.