qHash: fix compilation of SipHash64 on 32-bit: shift >= 32
Amends aadf1d447cd07a961539c6ab607ca65c3297622a because size_t on 32-bit platforms is 32-bit. qhash.cpp:331:15: error: left shift count >= width of type [-Werror=shift-count-overflow] Change-Id: I5f663c2f9f4149af84fefffd17c0567b17f832ce Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
This commit is contained in:
parent
facb6f9477
commit
58f93994d9
@ -320,13 +320,13 @@ template <int cROUNDS = 2, int dROUNDS = 4> struct SipHash64
|
||||
uint64_t k0;
|
||||
uint64_t k1;
|
||||
|
||||
inline SipHash64(size_t fulllen, uint64_t seed, uint64_t seed2);
|
||||
inline SipHash64(uint64_t fulllen, uint64_t seed, uint64_t seed2);
|
||||
inline void addBlock(const uint8_t *in, size_t inlen);
|
||||
inline uint64_t finalize(const uint8_t *in, size_t left);
|
||||
};
|
||||
|
||||
template <int cROUNDS, int dROUNDS>
|
||||
SipHash64<cROUNDS, dROUNDS>::SipHash64(size_t inlen, uint64_t seed, uint64_t seed2)
|
||||
SipHash64<cROUNDS, dROUNDS>::SipHash64(uint64_t inlen, uint64_t seed, uint64_t seed2)
|
||||
{
|
||||
b = inlen << 56;
|
||||
k0 = seed;
|
||||
|
Loading…
x
Reference in New Issue
Block a user