summaryrefslogtreecommitdiffhomepage
path: root/include
diff options
context:
space:
mode:
Diffstat (limited to 'include')
-rw-r--r--include/stc/ccommon.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/include/stc/ccommon.h b/include/stc/ccommon.h
index b0342928..68e45f43 100644
--- a/include/stc/ccommon.h
+++ b/include/stc/ccommon.h
@@ -123,7 +123,7 @@ STC_INLINE uint64_t c_fasthash(const void* key, size_t len) {
uint32_t u4;
const uint8_t *x = (const uint8_t*) key;
while (n--)
- memcpy(&u8, x, 8), x += 8, h += (h << 10) ^ (u8*0xc6a4a7935bd1e99d);
+ memcpy(&u8, x, 8), x += 8, h += (_c_ROTL(u8, 26) ^ u8)*0xc6a4a7935bd1e99d;
switch (len &= 7) {
case 0: return h;
case 4: memcpy(&u4, x, 4); return h + u4*0xc6a4a7935bd1e99d;