# HG changeset patch # User Richard M. Stallman # Date 1156492032 0 # Node ID 1ef51160f403c1a4555d4d4b35e8b084b8d211f5 # Parent b35bf6359ff43cde3a7865bdc1f0161a2a2055ba (sxhash_string): Rotate properly; don't lose bits. diff -r b35bf6359ff4 -r 1ef51160f403 src/fns.c --- 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;