Fixes errors thrown by GCC's Undefined Behaviour sanitizer (ubsan) every time this macro is used.
Signed-off-by: Eric Engestrom <eric.engest...@intel.com> --- src/util/bitset.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/util/bitset.h b/src/util/bitset.h index adafc72a5f74d46e118a..3b18abac793a0694c611 100644 --- a/src/util/bitset.h +++ b/src/util/bitset.h @@ -54,7 +54,7 @@ #define BITSET_ONES(x) memset( (x), 0xff, sizeof (x) ) #define BITSET_BITWORD(b) ((b) / BITSET_WORDBITS) -#define BITSET_BIT(b) (1 << ((b) % BITSET_WORDBITS)) +#define BITSET_BIT(b) (1u << ((b) % BITSET_WORDBITS)) /* single bit operations */ -- Cheers, Eric _______________________________________________ mesa-dev mailing list mesa-dev@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/mesa-dev