]> git.eshelyaron.com Git - emacs.git/commitdiff
(sxhash_string): Rotate properly; don't lose bits.
authorRichard M. Stallman <rms@gnu.org>
Fri, 25 Aug 2006 07:47:12 +0000 (07:47 +0000)
committerRichard M. Stallman <rms@gnu.org>
Fri, 25 Aug 2006 07:47:12 +0000 (07:47 +0000)
src/fns.c

index ca4a098878a37540d1a01efb4d7ceb3c2c4bff80..228d48049f0758cbbe0e5c5704413617aab8ea33 100644 (file)
--- a/src/fns.c
+++ b/src/fns.c
@@ -5027,7 +5027,7 @@ sxhash_string (ptr, len)
       c = *p++;
       if (c >= 0140)
        c -= 40;
-      hash = ((hash << 3) + (hash >> 28) + c);
+      hash = ((hash << 4) + (hash >> 28) + c);
     }
 
   return hash & INTMASK;