From 5bd8c389a3625e5c3eed265942d4c5b1e7e5d117 Mon Sep 17 00:00:00 2001 From: Marcel Raad Date: Sun, 8 Jul 2018 16:44:32 +0200 Subject: examples: fix -Wformat warnings When size_t is not a typedef for unsigned long (as usually the case on Windows), GCC emits -Wformat warnings when using lu and lx format specifiers with size_t. Silence them with explicit casts to unsigned long. Closes https://github.com/curl/curl/pull/2721 --- docs/examples/http2-download.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'docs/examples/http2-download.c') diff --git a/docs/examples/http2-download.c b/docs/examples/http2-download.c index cc9ff2b58..3425d302f 100644 --- a/docs/examples/http2-download.c +++ b/docs/examples/http2-download.c @@ -72,11 +72,11 @@ void dump(const char *text, int num, unsigned char *ptr, size_t size, width = 0x40; fprintf(stderr, "%d %s, %lu bytes (0x%lx)\n", - num, text, size, size); + num, text, (unsigned long)size, (unsigned long)size); for(i = 0; i