From 95d81bc26dfcf5ed3a955d8be4064bc5f26a1a46 Mon Sep 17 00:00:00 2001 From: Alexis Ballier Date: Tue, 2 Aug 2016 15:35:28 +0200 Subject: [PATCH] Use proper format specifiers for size_t. --- compiler/capnpc-c.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/compiler/capnpc-c.c b/compiler/capnpc-c.c index 75b3e43..d71ca66 100644 --- a/compiler/capnpc-c.c +++ b/compiler/capnpc-c.c @@ -1354,7 +1354,7 @@ int main() { if (g_valseg.len > 8) { size_t k; - fprintf(srcf, "static const uint8_t capn_buf[%lu] = {", g_valseg.len-8); + fprintf(srcf, "static const uint8_t capn_buf[%zu] = {", g_valseg.len-8); for (k = 8; k < g_valseg.len; k++) { if (k > 8) fprintf(srcf, ","); @@ -1364,7 +1364,7 @@ int main() { } fprintf(srcf, "\n};\n"); - fprintf(srcf, "static const struct capn_segment capn_seg = {{0},0,0,0,(char*)&capn_buf[0],%lu,%lu};\n", + fprintf(srcf, "static const struct capn_segment capn_seg = {{0},0,0,0,(char*)&capn_buf[0],%zu,%zu};\n", g_valseg.len-8, g_valseg.len-8); }