libc: Fix -Wformat.
authorSascha Wildner <saw@online.de>
Thu, 28 Mar 2013 22:13:44 +0000 (23:13 +0100)
committerSascha Wildner <saw@online.de>
Sat, 30 Mar 2013 11:54:54 +0000 (12:54 +0100)
lib/libc/gen/getdevpath.c
lib/libc/stdlib/nmalloc.c

index 1f9ba12..1f96925 100644 (file)
@@ -124,7 +124,7 @@ finddevlabel(char **pathp, const char *devname)
                 */
                ptr1 = strchr(prefix, ':');
                len = (ptr1) ? (size_t)(ptr1 - prefix) : strlen(prefix);
-               asprintf(&dtpath, "%*.*s/devtab", len, len, prefix);
+               asprintf(&dtpath, "%*.*s/devtab", (int)len, (int)len, prefix);
 
                /*
                 * Each devtab file
index b1a6f29..7c79013 100644 (file)
@@ -602,7 +602,7 @@ zoneindex(size_t *bytes, size_t *chunking)
                return(n / 2048 + 63);
        }
 #endif
-       _mpanic("Unexpected byte count %d", n);
+       _mpanic("Unexpected byte count %zu", n);
        return(0);
 }