diff options
| -rw-r--r-- | src/util/bitset.h | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/util/bitset.h b/src/util/bitset.h index cffbb73ecce..d5abb6c1f7c 100644 --- a/src/util/bitset.h +++ b/src/util/bitset.h @@ -209,7 +209,8 @@ __bitset_shl(BITSET_WORD *x, unsigned amount, unsigned n) */ #define BITSET_TEST_RANGE_INSIDE_WORD(x, b, e, mask) \ (BITSET_BITWORD(b) == BITSET_BITWORD(e) ? \ - (((x)[BITSET_BITWORD(b)] & BITSET_RANGE(b, e)) == mask) : \ + (((x)[BITSET_BITWORD(b)] & BITSET_RANGE(b, e)) == \ + (((BITSET_WORD)mask) << (b % BITSET_WORDBITS))) : \ (assert (!"BITSET_TEST_RANGE: bit range crosses word boundary"), 0)) #define BITSET_SET_RANGE_INSIDE_WORD(x, b, e) \ (BITSET_BITWORD(b) == BITSET_BITWORD(e) ? \ |