From 07a87aa599a8fc32e938d9987bd2b59eebcfcb76 Mon Sep 17 00:00:00 2001 From: Kevin Cernekee Date: Mon, 26 Jul 2010 11:37:19 -0700 Subject: mtd-utils: clean up compile warnings MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit gcc 4.4.3 on x86_64: libcrc32.c:42: warning: ‘static’ is not at beginning of declaration libfec.c:120: warning: initialization discards qualifiers from pointer target type libfec.c:121: warning: initialization discards qualifiers from pointer target type libfec.c:417: warning: passing argument 2 of ‘my_malloc’ discards qualifiers from pointer target type recv_image.c:164: warning: comparison of unsigned expression < 0 is always false recv_image.c:170: warning: format ‘%d’ expects type ‘int’, but argument 3 has type ‘size_t’ recv_image.c:170: warning: format ‘%d’ expects type ‘int’, but argument 4 has type ‘long unsigned int’ And many more along the same lines. Signed-off-by: Kevin Cernekee Signed-off-by: Artem Bityutskiy --- mtd_debug.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'mtd_debug.c') diff --git a/mtd_debug.c b/mtd_debug.c index 4934699..928cb5a 100644 --- a/mtd_debug.c +++ b/mtd_debug.c @@ -158,7 +158,7 @@ retry: if (buf != NULL) free (buf); close (outfd); - printf ("Copied %d bytes from address 0x%.8x in flash to %s\n",len,offset,filename); + printf ("Copied %zu bytes from address 0x%.8x in flash to %s\n",len,offset,filename); return (0); err2: @@ -309,7 +309,7 @@ int showinfo (int fd) { if (first) { - printf (flags[i].name); + printf ("%s", flags[i].name); first = 0; } else printf (" | %s",flags[i].name); -- cgit v1.2.3