author | alanb |
Sat, 27 Feb 2010 19:29:15 +0000 | |
changeset 4982 | 8e7376ac6830 |
parent 4981 | 3a3f498acc86 |
child 4984 | 48c6904d5e14 |
--- a/jdk/src/share/classes/java/lang/String.java Sat Feb 27 19:26:59 2010 +0000 +++ b/jdk/src/share/classes/java/lang/String.java Sat Feb 27 19:29:15 2010 +0000 @@ -1492,7 +1492,7 @@ */ public int hashCode() { int h = hash; - if (h == 0) { + if (h == 0 && count > 0) { int off = offset; char val[] = value; int len = count;