Use U, not UL, for 32-bit platforms
size_t is an unsigned int on 32-bit platforms, not an unsigned long.
This commit is contained in:
@@ -64,7 +64,7 @@ sudo_pow2_roundup_v2(size_t len)
|
||||
#if defined(__LP64__) && defined(HAVE___BUILTIN_CLZL)
|
||||
return 1UL << (64 - __builtin_clzl(len - 1));
|
||||
#elif !defined(__LP64__) && defined(HAVE___BUILTIN_CLZ)
|
||||
return 1UL << (32 - __builtin_clz(len - 1));
|
||||
return 1U << (32 - __builtin_clz(len - 1));
|
||||
#else
|
||||
len--;
|
||||
len |= len >> 1;
|
||||
|
Reference in New Issue
Block a user