From fda105ebd18f050d8071f62add2933ecbff8b8a7 Mon Sep 17 00:00:00 2001 From: David Steele Date: Sun, 24 Jan 2021 15:15:50 -0500 Subject: [PATCH] Add casts to performance/storage test for 32-bit architectures. --- test/src/module/performance/storageTest.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/test/src/module/performance/storageTest.c b/test/src/module/performance/storageTest.c index d05a28336..b0445b59a 100644 --- a/test/src/module/performance/storageTest.c +++ b/test/src/module/performance/storageTest.c @@ -237,7 +237,7 @@ testRun(void) ASSERT(bufUsed(block) == 1024 * 1024); // Build the input buffer - Buffer *input = bufNew(blockTotal * bufSize(block)); + Buffer *input = bufNew((size_t)blockTotal * bufSize(block)); for (unsigned int blockIdx = 0; blockIdx < blockTotal; blockIdx++) memcpy(bufPtr(input) + (blockIdx * bufSize(block)), bufPtr(block), bufSize(block)); @@ -246,7 +246,7 @@ testRun(void) // ------------------------------------------------------------------------------------------------------------------------- TEST_TITLE_FMT( - "%u iteration(s) of %" PRIu64 "MiB with %" PRIu64 "MB/s input, %" PRIu64 "MB/s output", iteration, + "%u iteration(s) of %zuMiB with %" PRIu64 "MB/s input, %" PRIu64 "MB/s output", iteration, bufUsed(input) / bufUsed(block), rateIn, rateOut); #define BENCHMARK_BEGIN() \