Skip to content

Commit e4d294c

Browse files
thom311keszybz
authored andcommitted
macro: fix ALIGN_TO() to use ULLONG_MAX instead of ULONGLONG_MAX
<limits.h> calls this ULLONG_MAX. It's not clear to me where ULONGLONG_MAX can be found. This seems to be just a mistake. Fixes: c7ed718 ('macro: handle overflow in ALIGN_TO() somewhat reasonably')
1 parent e338284 commit e4d294c

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/basic/macro.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -151,7 +151,7 @@ static inline size_t ALIGN_TO(size_t l, size_t ali) {
151151
assert(__builtin_popcount(ali) == 1);
152152
#elif SIZE_MAX == ULONG_MAX
153153
assert(__builtin_popcountl(ali) == 1);
154-
#elif SIZE_MAX == ULONGLONG_MAX
154+
#elif SIZE_MAX == ULLONG_MAX
155155
assert(__builtin_popcountll(ali) == 1);
156156
#else
157157
#error "Unexpected size_t"

0 commit comments

Comments
 (0)