From 1920a99115949dc946f044b10f0ba978319acddb Mon Sep 17 00:00:00 2001 From: Natalie Vock Date: Tue, 21 Oct 2025 11:12:22 +0200 Subject: util/bitset: Wrap __size in braces Otherwise funny things can happen with the < operator because of precedence rules. Reviewed-by: Alyssa Rosenzweig Part-of: --- 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 7e10b78c2eb..0f13b4ce2ec 100644 --- a/src/util/bitset.h +++ b/src/util/bitset.h @@ -423,7 +423,7 @@ __bitset_next_set(unsigned i, BITSET_WORD *tmp, #define BITSET_FOREACH_SET(__i, __set, __size) \ for (BITSET_WORD __tmp = (__size) == 0 ? 0 : *(__set), *__foo = &__tmp; __foo != NULL; __foo = NULL) \ for (__i = 0; \ - (__i = __bitset_next_set(__i, &__tmp, __set, __size)) < __size;) + (__i = __bitset_next_set(__i, &__tmp, __set, __size)) < (__size);) static inline void __bitset_next_range(unsigned *start, unsigned *end, const BITSET_WORD *set, -- cgit v1.2.3