diff options
author | Tarmigan Casebolt <tarmigan+git@gmail.com> | 2009-11-15 00:33:13 +0300 |
---|---|---|
committer | Junio C Hamano <gitster@pobox.com> | 2009-11-16 05:24:58 +0300 |
commit | 28bea9e53481fddcb12e63d8c049f0ff2917a573 (patch) | |
tree | 1f38ad659ae1b5af3ae05b788c4b6bebb49961f5 /builtin-fsck.c | |
parent | 77097faa5dc3da2947f4a4bdb6f8a7766f4ef89a (diff) |
Check the format of more printf-type functions
We already have these checks in many printf-type functions that have
prototypes which are in header files. Add these same checks to some
more prototypes in header functions and to static functions in .c
files.
cc: Miklos Vajna <vmiklos@frugalware.org>
Signed-off-by: Tarmigan Casebolt <tarmigan+git@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'builtin-fsck.c')
-rw-r--r-- | builtin-fsck.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/builtin-fsck.c b/builtin-fsck.c index 2d88e4570f..0e5faae381 100644 --- a/builtin-fsck.c +++ b/builtin-fsck.c @@ -47,6 +47,7 @@ static void objreport(struct object *obj, const char *severity, fputs("\n", stderr); } +__attribute__((format (printf, 2, 3))) static int objerror(struct object *obj, const char *err, ...) { va_list params; @@ -57,6 +58,7 @@ static int objerror(struct object *obj, const char *err, ...) return -1; } +__attribute__((format (printf, 3, 4))) static int fsck_error_func(struct object *obj, int type, const char *err, ...) { va_list params; |