changeset 72511:1ef51160f403

(sxhash_string): Rotate properly; don't lose bits.
author Richard M. Stallman <rms@gnu.org>
date Fri, 25 Aug 2006 07:47:12 +0000
parents b35bf6359ff4
children ab8fd2fba72d
files src/fns.c
diffstat 1 files changed, 1 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/src/fns.c	Fri Aug 25 02:58:08 2006 +0000
+++ b/src/fns.c	Fri Aug 25 07:47:12 2006 +0000
@@ -5027,7 +5027,7 @@
       c = *p++;
       if (c >= 0140)
 	c -= 40;
-      hash = ((hash << 3) + (hash >> 28) + c);
+      hash = ((hash << 4) + (hash >> 28) + c);
     }
 
   return hash & INTMASK;