Skip to content

Commit 7868716

Browse files
rscharfegitster
authored andcommitted
t-strvec: fix type mismatch in check_strvec
Cast i from size_t to uintmax_t to match the format string. Reported-by: Jeff King <[email protected]> Signed-off-by: René Scharfe <[email protected]> Signed-off-by: Junio C Hamano <[email protected]>
1 parent 141e13e commit 7868716

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

t/unit-tests/t-strvec.c

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,8 @@
1111
check_uint((vec)->nr, <=, (vec)->alloc)) { \
1212
for (size_t i = 0; i < ARRAY_SIZE(expect); i++) { \
1313
if (!check_str((vec)->v[i], expect[i])) { \
14-
test_msg(" i: %"PRIuMAX, i); \
14+
test_msg(" i: %"PRIuMAX, \
15+
(uintmax_t)i); \
1516
break; \
1617
} \
1718
} \

0 commit comments

Comments
 (0)