From 078809d34ea1d7bc46311c99bb5285f1677d0bf3 Mon Sep 17 00:00:00 2001 From: keescook Date: Tue, 29 Apr 2008 17:09:57 +0000 Subject: [PATCH] make format string warnings fatal, since it should never happen --- build.xml | 2 +- configure.ac | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/build.xml b/build.xml index d0c4074f6..91b6eb007 100644 --- a/build.xml +++ b/build.xml @@ -276,7 +276,7 @@ - -Wall -Wformat-security -W -Wpointer-arith -Wcast-align -Wsign-compare -Woverloaded-virtual -Wswitch + -Wall -Wformat -Werror=format-security -W -Wpointer-arith -Wcast-align -Wsign-compare -Woverloaded-virtual -Wswitch -O2 -mms-bitfields diff --git a/configure.ac b/configure.ac index 9cecae403..313d349a8 100644 --- a/configure.ac +++ b/configure.ac @@ -43,7 +43,7 @@ if test "$GCC" = "yes"; then ink_svd_CFLAGS="$CFLAGS" CFLAGS="-Wno-pointer-sign $CFLAGS" AC_COMPILE_IFELSE(AC_LANG_PROGRAM([]), AC_MSG_NOTICE([ compiler supports -Wno-pointer-sign]), CFLAGS="$ink_svd_CFLAGS") - CFLAGS="-Wall -Wformat-security -W -D_FORTIFY_SOURCE=2 $CFLAGS" + CFLAGS="-Wall -Wformat -Werror=format-security -W -D_FORTIFY_SOURCE=2 $CFLAGS" AC_LANG_POP fi @@ -751,7 +751,7 @@ if test "$GXX" = "yes"; then # programmer deliberately has an unused parameter (e.g. because it's used # as a callback or similar function pointer use). - CXXFLAGS="-Wall -Wformat-security -W -Wpointer-arith -Wcast-align -Wsign-compare -Woverloaded-virtual -Wswitch -D_FORTIFY_SOURCE=2 $CXXFLAGS" + CXXFLAGS="-Wall -Wformat -Werror=format-security -W -Wpointer-arith -Wcast-align -Wsign-compare -Woverloaded-virtual -Wswitch -D_FORTIFY_SOURCE=2 $CXXFLAGS" dnl Test for arch-specific situations. case "$host_cpu" in -- 2.30.2