Makefile.in: introduce -Wunused-function
authorIan Jackson <ijackson@chiark.greenend.org.uk>
Sun, 11 May 2014 15:36:52 +0000 (16:36 +0100)
committerIan Jackson <ijackson@chiark.greenend.org.uk>
Thu, 15 May 2014 01:02:13 +0000 (02:02 +0100)
And delete the two unused logging functions log_multi and syslog_log.

Signed-off-by: Ian Jackson <ijackson@chiark.greenend.org.uk>
Makefile.in
log.c

index c224a08..ba5a861 100644 (file)
@@ -36,7 +36,7 @@ CFLAGS:=-Wall @WRITESTRINGS@ @CFLAGS@ -Werror \
        -Wno-pointer-sign -Wstrict-prototypes -Wmissing-prototypes \
        -Wmissing-declarations -Wnested-externs -Wredundant-decls \
        -Wpointer-arith -Wformat=2 -Winit-self \
-       -Wswitch-enum -Wunused-variable -Wbad-function-cast \
+       -Wswitch-enum -Wunused-variable -Wunused-function -Wbad-function-cast \
        -Wno-strict-aliasing -fno-strict-aliasing
 ALL_CFLAGS:=@DEFS@ -I$(srcdir) -I. $(CFLAGS) $(EXTRA_CFLAGS)
 CPPFLAGS:=@CPPFLAGS@ $(EXTRA_CPPFLAGS)
diff --git a/log.c b/log.c
index 4aa12e7..326a891 100644 (file)
--- a/log.c
+++ b/log.c
@@ -189,17 +189,6 @@ static void log_vmulti(void *sst, int class, const char *message, va_list args)
     }
 }
 
-static void log_multi(void *st, int priority, const char *message, ...)
-    FORMAT(printf,3,4);
-static void log_multi(void *st, int priority, const char *message, ...)
-{
-    va_list ap;
-
-    va_start(ap,message);
-    log_vmulti(st,priority,message,ap);
-    va_end(ap);
-}
-
 struct log_if *init_log(list_t *ll)
 {
     int i=0;
@@ -409,17 +398,6 @@ static void syslog_vlog(void *sst, int class, const char *message,
     }
 }
 
-static void syslog_log(void *sst, int priority, const char *message, ...)
-    FORMAT(printf,3,4);
-static void syslog_log(void *sst, int priority, const char *message, ...)
-{
-    va_list ap;
-
-    va_start(ap,message);
-    syslog_vlog(sst,priority,message,ap);
-    va_end(ap);
-}
-
 static struct flagstr syslog_facility_table[]={
 #ifdef LOG_AUTH
     { "auth", LOG_AUTH },