macro: don't rely on C's downgrade-to-bool feature for numeric comparisons

This commit is contained in:
Lennart Poettering
2018-04-12 11:02:47 +02:00
parent 42ce5f75bf
commit ce2090ab72
+1 -1
View File
@@ -350,7 +350,7 @@ static inline unsigned long ALIGN_POWER2(unsigned long u) {
({ \
typeof(x) _x_ = (x); \
unsigned ans = 1; \
while (_x_ /= 10) \
while ((_x_ /= 10) != 0) \
ans++; \
ans; \
})