Blob Blame History Raw
From f5793fd6789875bf29b50f7df0e6df24bf797494 Mon Sep 17 00:00:00 2001
From: Volker Gropp <volker@gropp.org>
Date: Mon, 1 Nov 2021 09:39:31 +0100
Subject: [PATCH] fix: format not a string literal

... and no format arguments
https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=997140

Remove unintended files
Signed-off-by: Tim Orling <ticotimo@gmail.com>
---
 configure.in | 4 ++--
 src/output.c | 2 +-
 2 files changed, 3 insertions(+), 3 deletions(-)

diff --git a/configure.in b/configure.in
index 282bf1e..2cd6811 100644
--- a/configure.in
+++ b/configure.in
@@ -12,7 +12,7 @@ AC_ARG_ENABLE([debug],AS_HELP_STRING([--enable-debug],[enable debug (default: no
 echo "enable debugging info: $enableval"
 if [ test $enableval = "yes" ]; then
     if test -z ${CFLAGS}; then
-        CFLAGS="-g3 -Wall"
+        CFLAGS="-g3 -Werror=format-security -Wall"
     else
         CFLAGS="-g3 ${CFLAGS}"
     fi
@@ -20,7 +20,7 @@ if [ test $enableval = "yes" ]; then
 fi
 ],[
 if test -z "${CFLAGS}"; then
-    CFLAGS="-O2 -Wall"
+    CFLAGS="-O2 -Wall -Werror=format-security"
 fi
 ])
 
diff --git a/src/output.c b/src/output.c
index f5f01cd..81fdcef 100644
--- a/src/output.c
+++ b/src/output.c
@@ -151,7 +151,7 @@ int print_header(int option) {
 	        erase();
 		    mvwprintw(stdscr,1,2,"bwm-ng v" VERSION" (probing every %2.3fs), press 'h' for help",(float)delay/1000);
             mvwprintw(stdscr,2,2,"input: %s type: %s",input2str(),output_type2str());
-            wprintw(stdscr,show_all_if2str());
+            wprintw(stdscr,"%s",show_all_if2str());
 	        mvwprintw(stdscr,3,2,"%c         iface                   Rx                   Tx                Total",(char)IDLE_CHARS[option]);
 	        /* go to next char for next run */
 	        option++;
-- 
2.39.2