OSDN Git Service

Fix format strings warnings.
authorrelan <relan@users.noreply.github.com>
Sun, 20 Dec 2009 16:14:10 +0000 (16:14 +0000)
committerrelan <relan@users.noreply.github.com>
Mon, 24 Aug 2015 05:26:11 +0000 (08:26 +0300)
libexfat/io.c

index 9355e51..34144af 100644 (file)
@@ -8,6 +8,7 @@
  */
 
 #include "exfat.h"
+#include <inttypes.h>
 #include <sys/types.h>
 #include <sys/uio.h>
 #define __USE_UNIX98 /* for pread() in Linux */
 void exfat_read_raw(void* buffer, size_t size, off_t offset, int fd)
 {
        if (pread(fd, buffer, size, offset) != size)
-               exfat_bug("failed to read %zu bytes from file at %llu", size, offset);
+               exfat_bug("failed to read %zu bytes from file at %"PRIu64, size,
+                               (uint64_t) offset);
 }
 
 void exfat_write_raw(const void* buffer, size_t size, off_t offset, int fd)
 {
        if (pwrite(fd, buffer, size, offset) != size)
-               exfat_bug("failed to write %zu bytes to file at %llu", size, offset);
+               exfat_bug("failed to write %zu bytes to file at %"PRIu64, size,
+                               (uint64_t) offset);
 }
 
 ssize_t exfat_read(const struct exfat* ef, struct exfat_node* node,