OSDN Git Service

Add attributes for printf-style functions.
authorrelan <relan@users.noreply.github.com>
Sun, 20 Dec 2009 16:05:30 +0000 (16:05 +0000)
committerrelan <relan@users.noreply.github.com>
Mon, 24 Aug 2015 05:26:11 +0000 (08:26 +0300)
libexfat/exfat.h

index b9165af..e443cfd 100644 (file)
@@ -82,10 +82,14 @@ struct exfat_iterator
 
 extern int exfat_errors;
 
-void exfat_bug(const char* format, ...);
-void exfat_error(const char* format, ...);
-void exfat_warn(const char* format, ...);
-void exfat_debug(const char* format, ...);
+void exfat_bug(const char* format, ...)
+       __attribute__((format(printf, 1, 2), noreturn));
+void exfat_error(const char* format, ...)
+       __attribute__((format(printf, 1, 2)));
+void exfat_warn(const char* format, ...)
+       __attribute__((format(printf, 1, 2)));
+void exfat_debug(const char* format, ...)
+       __attribute__((format(printf, 1, 2)));
 
 void exfat_read_raw(void* buffer, size_t size, off_t offset, int fd);
 void exfat_write_raw(const void* buffer, size_t size, off_t offset, int fd);