2
0
mirror of git://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git synced 2025-09-04 20:19:47 +08:00

net: sctp: attribute printl with __printf for gcc fmt checks

Let GCC check for format string errors in sctp's probe printl
function. This patch fixes the warning when compiled with W=1:

net/sctp/probe.c:73:2: warning: function might be possible candidate
for 'gnu_printf' format attribute [-Wmissing-format-attribute]

Signed-off-by: Daniel Borkmann <dborkman@redhat.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
This commit is contained in:
Daniel Borkmann 2013-05-01 02:59:23 +00:00 committed by David S. Miller
parent ee1bec9b3b
commit be3e45810b

View File

@ -63,7 +63,7 @@ static struct {
struct timespec tstart; struct timespec tstart;
} sctpw; } sctpw;
static void printl(const char *fmt, ...) static __printf(1, 2) void printl(const char *fmt, ...)
{ {
va_list args; va_list args;
int len; int len;