summaryrefslogtreecommitdiffstats
path: root/waftools/detections
diff options
context:
space:
mode:
authorwm4 <wm4@nowhere>2019-12-11 17:23:39 +0100
committerwm4 <wm4@nowhere>2019-12-11 17:28:47 +0100
commitc84460f61fa2417511193803d0afcf4ac903ad4f (patch)
tree393bc05e57523bc9e39033c57ae116540ea34536 /waftools/detections
parentc68251a3a72f8284e6cb7808a57e2e5137376c3a (diff)
downloadmpv-c84460f61fa2417511193803d0afcf4ac903ad4f.tar.bz2
mpv-c84460f61fa2417511193803d0afcf4ac903ad4f.tar.xz
build: add -Wimplicit-fallthrough
This warning seems to be designed well. It doesn't seem to warn on fallthrough-only case statements, so it's compatible to well written code. stream_dvdnav.c had an obscure bug in inactive code, fix it. stream_dvb.c is the only place where it intentionally falls through, I guess I'll just leave it alone.
Diffstat (limited to 'waftools/detections')
-rw-r--r--waftools/detections/compiler.py4
1 files changed, 3 insertions, 1 deletions
diff --git a/waftools/detections/compiler.py b/waftools/detections/compiler.py
index c9b11f5f6d..6946710900 100644
--- a/waftools/detections/compiler.py
+++ b/waftools/detections/compiler.py
@@ -41,7 +41,9 @@ def __add_generic_flags__(ctx):
"-Werror=format-security",
"-Wno-redundant-decls",
"-Wvla",
- "-Wno-format-truncation"])
+ "-Wno-format-truncation",
+ "-Wimplicit-fallthrough",
+ ])
def __add_gcc_flags__(ctx):
ctx.env.CFLAGS += ["-Wall", "-Wundef", "-Wmissing-prototypes", "-Wshadow",