From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([208.118.235.92]:39124) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1USvKW-0004Rt-N7 for qemu-devel@nongnu.org; Thu, 18 Apr 2013 16:21:20 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1USvKS-00010C-Ns for qemu-devel@nongnu.org; Thu, 18 Apr 2013 16:21:16 -0400 From: Stefan Weil Date: Thu, 18 Apr 2013 22:21:05 +0200 Message-Id: <1366316465-32710-1-git-send-email-sw@weilnetz.de> Subject: [Qemu-devel] [PATCH] block/ssh: Add missing gcc format attributes List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: qemu-trivial@nongnu.org Cc: Stefan Weil , qemu-devel@nongnu.org, "Richard W.M. Jones" Now gcc will check whether format string and variable arguments match. Signed-off-by: Stefan Weil --- Please note: I could only run limited tests with the new code because ssh.c is currently not compiled in my w32/w64 environment. Regards, Stefan W. block/ssh.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/block/ssh.c b/block/ssh.c index 8f78e2e..b4e048c 100644 --- a/block/ssh.c +++ b/block/ssh.c @@ -109,7 +109,7 @@ static void ssh_state_free(BDRVSSHState *s) /* Wrappers around error_report which make sure to dump as much * information from libssh2 as possible. */ -static void +static void GCC_FMT_ATTR(2, 3) session_error_report(BDRVSSHState *s, const char *fs, ...) { va_list args; @@ -132,7 +132,7 @@ session_error_report(BDRVSSHState *s, const char *fs, ...) error_printf("\n"); } -static void +static void GCC_FMT_ATTR(2, 3) sftp_error_report(BDRVSSHState *s, const char *fs, ...) { va_list args; -- 1.7.10.4