From 8d80010b7bca1c28ff4c65a77f561b36992d2f54 Mon Sep 17 00:00:00 2001 From: Yann Collet Date: Sat, 22 Feb 2020 10:07:01 -0800 Subject: [PATCH] fixed seed space reduction thanks to @easyaspi314 --- xxh3.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/xxh3.h b/xxh3.h index ec8b2a0..302e9bc 100644 --- a/xxh3.h +++ b/xxh3.h @@ -574,7 +574,7 @@ XXH3_len_4to8_64b(const xxh_u8* input, size_t len, const xxh_u8* secret, XXH64_h XXH_ASSERT(input != NULL); XXH_ASSERT(secret != NULL); XXH_ASSERT(4 <= len && len < 8); - seed ^= XXH_swap64(seed); + seed ^= seed << 32; { xxh_u32 const input1 = XXH_readLE32(input); xxh_u32 const input2 = XXH_readLE32(input + len - 4); xxh_u32 const key1 = XXH_swap32(input1) ^ ((xxh_u32)(seed >> 32) + XXH_readLE32(secret));