memlock: avoid type confusion in format string
authorSitsofe Wheeler <sitsofe@yahoo.com>
Mon, 31 Aug 2020 10:44:11 +0000 (11:44 +0100)
committerSitsofe Wheeler <sitsofe@yahoo.com>
Sat, 12 Sep 2020 10:54:19 +0000 (11:54 +0100)
commit32b0e8c3ba9a5c59e556d9a550fd21029a4510f1
tree776748aeac7ff521c0342a555cc7461e2748efe1
parent8a2cf08d29ac7b33e4aa2376c68be4c431d11c6c
memlock: avoid type confusion in format string

Windows GCC has the followng grumble:

t/memlock.c: In function 'worker':
t/memlock.c:25:26: error: format '%lu' expects argument of type 'long unsigned int', but argument 3 has type 'size_t' {aka 'long long unsigned int'} [-Werror=format=]
   25 |    printf("loop%d: did %lu MiB\n", i+1, size/(1024UL*1024UL));
      |                        ~~^              ~~~~~~~~~~~~~~~~~~~~
      |                          |                  |
      |                          long unsigned int  size_t {aka long long unsigned int}
      |                        %llu

Fix it up by just using the original variable that was already in
megabytes.

Signed-off-by: Sitsofe Wheeler <sitsofe@yahoo.com>
t/memlock.c