commit | eddcb3bae10f057a1483386d8fc17487b03d9145 | [log] [tgz] |
---|---|---|
author | Guido van Rossum <guido@python.org> | Wed Sep 11 20:22:48 1996 +0000 |
committer | Guido van Rossum <guido@python.org> | Wed Sep 11 20:22:48 1996 +0000 |
tree | 04adff753a215fd53cd005244aeecd58820f6379 | |
parent | b23a60fd6ef357bb279e8525d9b3042cfb886b94 [diff] [blame] |
Multiply by 1000003 instead of 3 in string hach
diff --git a/Objects/stringobject.c b/Objects/stringobject.c index 1e11c50..3dfe115 100644 --- a/Objects/stringobject.c +++ b/Objects/stringobject.c
@@ -419,7 +419,7 @@ p = (unsigned char *) a->ob_sval; x = *p << 7; while (--len >= 0) - x = (3*x) ^ *p++; + x = (1000003*x) ^ *p++; x ^= a->ob_size; if (x == -1) x = -2;