]> www.infradead.org Git - mtd-utils.git/commitdiff
tests: checkfs: fix compiler warnings
authorAndy Shevchenko <ext-andriy.shevchenko@nokia.com>
Tue, 5 Apr 2011 13:55:50 +0000 (16:55 +0300)
committerArtem Bityutskiy <Artem.Bityutskiy@nokia.com>
Tue, 5 Apr 2011 14:13:47 +0000 (17:13 +0300)
There are two warnings:
 - strlen() is used without prototype
 - argument of printf() is unsigned long, but used specifier is for int

This patch fixes them.

Signed-off-by: Andy Shevchenko <ext-andriy.shevchenko@nokia.com>
Signed-off-by: Artem Bityutskiy <Artem.Bityutskiy@nokia.com>
tests/checkfs/checkfs.c
tests/checkfs/comm.c

index da2d0c4cc1b3c253d39233d97207f8282e84b63d..6ca2c0ee3a9497e8db5186da1a4127736fdc8804 100644 (file)
@@ -520,7 +520,7 @@ void processCmdLine(int argc, char **argv)
                 FileSizeMax = (float)atoi(argv[++cnt]);
                 if(FileSizeMax > (MAX_INTS_ALLOW*sizeof(int)))
                 {
-                    printf("Max file size allowd is %i.\n",
+                    printf("Max file size allowed is %lu.\n",
                            MAX_INTS_ALLOW*sizeof(int));
                     exit(0);
                 }
index 57fc7edb961fc073f8490e094dfde5a84de33263..881a270a41297c595a9177af8f2edf72d89e729b 100644 (file)
   Split the modbus comm part of the program (that sends the ok to pwr me down
   message) into another file "comm.c"
 
-
-
  */
 
 #include <stdio.h>
 #include <stdlib.h>
 #include <unistd.h>
-
-
+#include <string.h>
 
 /*
   This is the routine that forms and