*.c static functions: add missing __attribute__((format))
Add missing __attribute__((format)) function attributes to various "static" functions that take printf arguments. Signed-off-by: Ævar Arnfjörð Bjarmason <avarab@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
This commit is contained in:

committed by
Junio C Hamano

parent
d4ac305073
commit
48ca53cac4
@ -117,6 +117,7 @@ static int write_in_file(const char *path, const char *mode, const char *format,
|
||||
return fclose(fp);
|
||||
}
|
||||
|
||||
__attribute__((format (printf, 2, 3)))
|
||||
static int write_to_file(const char *path, const char *format, ...)
|
||||
{
|
||||
int res;
|
||||
@ -129,6 +130,7 @@ static int write_to_file(const char *path, const char *format, ...)
|
||||
return res;
|
||||
}
|
||||
|
||||
__attribute__((format (printf, 2, 3)))
|
||||
static int append_to_file(const char *path, const char *format, ...)
|
||||
{
|
||||
int res;
|
||||
|
Reference in New Issue
Block a user