From 062325818917381f48303eda9e9a76e1b91576b8 Mon Sep 17 00:00:00 2001 From: kervala Date: Mon, 30 Nov 2015 10:27:41 +0100 Subject: [PATCH] Fixed: 64 bits constants truncated in 32 bits --HG-- branch : develop --- code/nel/include/nel/misc/wang_hash.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/code/nel/include/nel/misc/wang_hash.h b/code/nel/include/nel/misc/wang_hash.h index b3069b92f..2b51087dd 100644 --- a/code/nel/include/nel/misc/wang_hash.h +++ b/code/nel/include/nel/misc/wang_hash.h @@ -45,7 +45,7 @@ inline uint64 wangHash64Inv(uint64 key) key = key^tmp >> 28; // Invert key *= 21 - key *= 14933078535860113213u; + key *= UINT64_CONSTANT(14933078535860113213); // Invert key = key ^ (key >> 14) tmp = key^key >> 14; @@ -54,7 +54,7 @@ inline uint64 wangHash64Inv(uint64 key) key = key^tmp >> 14; // Invert key *= 265 - key *= 15244667743933553977u; + key *= UINT64_CONSTANT(15244667743933553977); // Invert key = key ^ (key >> 24) tmp = key^key >> 24;