From 53a617f5e118ec5642daa3da45fcef0bf5593b12 Mon Sep 17 00:00:00 2001 From: Jim Meyering Date: Sun, 20 Oct 2013 11:32:58 -0700 Subject: [PATCH] error: add the printf attribute to a static function * lib/error.c (error_tail): Add the printf attribute, to placate gcc's -Werror=suggest-attribute=format option. --- ChangeLog | 6 ++++++ lib/error.c | 2 +- 2 files changed, 7 insertions(+), 1 deletion(-) diff --git a/ChangeLog b/ChangeLog index 77a1d0d..1855d16 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,9 @@ +2013-10-20 Jim Meyering + + error: add the printf attribute to a static function + * lib/error.c (error_tail): Add the printf attribute, to placate + gcc's -Werror=suggest-attribute=format option. + 2013-10-12 Jim Meyering error: make the module depend on vfprintf-posix diff --git a/lib/error.c b/lib/error.c index 865b293..cdc3026 100644 --- a/lib/error.c +++ b/lib/error.c @@ -195,7 +195,7 @@ print_errno_message (int errnum) #endif } -static void +static void _GL_ATTRIBUTE_FORMAT_PRINTF (3, 0) _GL_ARG_NONNULL ((3)) error_tail (int status, int errnum, const char *message, va_list args) { #if _LIBC -- 1.8.4.299.gb3e7d24