2
0
mirror of https://gitlab.isc.org/isc-projects/dhcp synced 2025-08-29 13:28:14 +00:00

[master] Fix test allocation message to use %zu

This commit is contained in:
Shawn Routhier 2016-07-27 11:05:13 -07:00
parent 10b7683e58
commit dd3373f457

View File

@ -551,7 +551,7 @@ void checkBuffer(size_t test_size, const char *file, int line) {
max_size = ((size_t)-1) - DMDSIZE; max_size = ((size_t)-1) - DMDSIZE;
if (test_size > max_size) { if (test_size > max_size) {
atf_tc_skip("Test size greater than max size, %lx", test_size); atf_tc_skip("Test size greater than max size, %zu", test_size);
return; return;
} }
@ -562,10 +562,10 @@ void checkBuffer(size_t test_size, const char *file, int line) {
if (buf != NULL) { if (buf != NULL) {
buf[test_size - 1] = 1; buf[test_size - 1] = 1;
if (buf[test_size - 1] != 1) if (buf[test_size - 1] != 1)
atf_tc_fail("Value mismatch for index %lu", test_size); atf_tc_fail("Value mismatch for index %zu", test_size);
dfree(buf, file, line); dfree(buf, file, line);
} else { } else {
atf_tc_skip("Unable to allocate memory %lu", test_size); atf_tc_skip("Unable to allocate memory %zu", test_size);
} }
} }