From 40e7cf5607052d3b4fa09fd433fa630352c115b6 Mon Sep 17 00:00:00 2001 From: Ben Pfaff Date: Sun, 7 Jun 2015 09:48:14 -0700 Subject: configure: Stop avoiding -Wformat-zero-length. Debian likes to enable -Wformat-zero-length, even over our code trying to disable it. It isn't too hard to make our code warning-free against this option, so this commit both stops disabling it and fixes the warnings. The first fix is to change set_subprogram_name() to take a plain string instead of a format string, and to adjust its few callers. This fixes one warning since one of those callers passed in an empty string. The second fix is to remove a test for ovs_scan() against an empty string. I couldn't find a way to avoid a warning for this test, and it isn't too valuable in any case. This allows us to drop filtering for -Wformat from the Debian rules file, so this commit removes it. Signed-off-by: Ben Pfaff --- configure.ac | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) (limited to 'configure.ac') diff --git a/configure.ac b/configure.ac index 068674ee7..be5cf086c 100644 --- a/configure.ac +++ b/configure.ac @@ -1,4 +1,4 @@ -# Copyright (c) 2008, 2009, 2010, 2011, 2012, 2013, 2014 Nicira, Inc. +# Copyright (c) 2008, 2009, 2010, 2011, 2012, 2013, 2014, 2015 Nicira, Inc. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. @@ -144,7 +144,6 @@ OVS_ENABLE_OPTION([-Wextra]) OVS_ENABLE_OPTION([-Wno-sign-compare]) OVS_ENABLE_OPTION([-Wpointer-arith]) OVS_ENABLE_OPTION([-Wformat-security]) -OVS_ENABLE_OPTION([-Wno-format-zero-length]) OVS_ENABLE_OPTION([-Wswitch-enum]) OVS_ENABLE_OPTION([-Wunused-parameter]) OVS_ENABLE_OPTION([-Wbad-function-cast]) -- cgit v1.2.1