Bug 568416 - fix hash computation to ensure non-negative hash
One out of 2^32 strings have a hashCode of Integer.MIN_VALUE, including
"polygenelubricants" "GydZG_" and ""DESIGNING WORKHOUSES".
This and the fact that Math.abs(Integer.MIN_VALUE) == Integer.MIN_VALUE
made it possible for the hash computation to return negative values
which will cause elements to not be added or looked up correctly.
Change-Id: Ib00299b8ed51592ab51e0b86836fde904129b98d
Signed-off-by: Thomas Watson <tjwatson@us.ibm.com>
1 file changed