From 75f1999b2c42042725b9ee782e135b0300cc384e Mon Sep 17 00:00:00 2001 From: Stephen Hemminger Date: Wed, 9 Dec 2009 17:28:49 +0000 Subject: vty: fix warnings Gcc now warns if function that takes printf style formatting is passed a non-constant string. This avoid issues when a format character is entered in some command. Signed-off-by: David Lamparter --- lib/if.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'lib/if.c') diff --git a/lib/if.c b/lib/if.c index e3107116..d14cfb93 100644 --- a/lib/if.c +++ b/lib/if.c @@ -664,7 +664,7 @@ connected_log (struct connected *connected, char *str) strncat (logbuf, inet_ntop (p->family, &p->u.prefix, buf, BUFSIZ), BUFSIZ - strlen(logbuf)); } - zlog (NULL, LOG_INFO, logbuf); + zlog (NULL, LOG_INFO, "%s", logbuf); } /* If two connected address has same prefix return 1. */ -- cgit v1.2.3