diff options
author | David Robillard <d@drobilla.net> | 2020-12-31 19:28:54 +0100 |
---|---|---|
committer | David Robillard <d@drobilla.net> | 2020-12-31 20:15:19 +0100 |
commit | 53e9bd0f9ea02c47510a47ab37901f2a284a3632 (patch) | |
tree | ce9b508ec356f2d4eaa32ca18c17277aed739773 /test/hash_test.c | |
parent | 585128b152486afd4c2a8811266bdd7cd04c746e (diff) | |
download | zix-53e9bd0f9ea02c47510a47ab37901f2a284a3632.tar.gz zix-53e9bd0f9ea02c47510a47ab37901f2a284a3632.tar.bz2 zix-53e9bd0f9ea02c47510a47ab37901f2a284a3632.zip |
Fix MinGW build
Diffstat (limited to 'test/hash_test.c')
-rw-r--r-- | test/hash_test.c | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/test/hash_test.c b/test/hash_test.c index 46a8fd5..2b9bb51 100644 --- a/test/hash_test.c +++ b/test/hash_test.c @@ -20,6 +20,7 @@ #include "zix/digest.h" #include "zix/hash.h" +#include <inttypes.h> #include <stdarg.h> #include <stdbool.h> #include <stdint.h> @@ -113,7 +114,9 @@ stress(void) // Ensure hash size is correct if (zix_hash_size(hash) != n_strings) { - return test_fail("Hash size %zu != %zu\n", zix_hash_size(hash), n_strings); + return test_fail("Hash size %" PRIuPTR " != %" PRIuPTR "\n", + zix_hash_size(hash), + n_strings); } // zix_hash_print_dot(hash, stdout); @@ -210,7 +213,7 @@ main(void) #ifdef ZIX_WITH_TEST_MALLOC const size_t total_n_allocs = test_malloc_get_n_allocs(); - printf("Testing 0 ... %zu failed allocations\n", total_n_allocs); + printf("Testing 0 ... %" PRIuPTR " failed allocations\n", total_n_allocs); expect_failure = true; for (size_t i = 0; i < total_n_allocs; ++i) { test_malloc_reset(i); |