diff options
author | Ben Chan <benchan@chromium.org> | 2018-12-10 10:56:05 -0800 |
---|---|---|
committer | Aleksander Morgado <aleksander@aleksander.es> | 2018-12-11 10:03:20 +0100 |
commit | ea42bbf13d3369664973c29f8bf07fd76bd43eef (patch) | |
tree | 5c44eb70562a6953d0557d63495780f00267c555 | |
parent | bff6abc1d7e424d7d594caba540ffe587fd0d723 (diff) |
build: enable -Wtype-limits
-Wtype-limits helps catch unnecessary comparisons such as comparing
unsigned variables <= 0.
This patch essentially brings the list of compiler warnings defined in
m4/compiler-warnings.m4 to be on par with libqmi.
-rw-r--r-- | m4/compiler-warnings.m4 | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/m4/compiler-warnings.m4 b/m4/compiler-warnings.m4 index eb78503..77b79c5 100644 --- a/m4/compiler-warnings.m4 +++ b/m4/compiler-warnings.m4 @@ -15,7 +15,7 @@ if test "$GCC" = "yes" -a "$set_more_warnings" != "no"; then -Wundef -Wimplicit-function-declaration \ -Wpointer-arith -Winit-self -Wshadow \ -Wmissing-include-dirs -Waggregate-return \ - -Wformat-security; do + -Wformat-security -Wtype-limits; do SAVE_CFLAGS="$CFLAGS" CFLAGS="$CFLAGS $option" AC_MSG_CHECKING([whether gcc understands $option]) |