From b3ae709ea68a2e98b1f1d2d52b9d4c48bfeb3c30 Mon Sep 17 00:00:00 2001 From: Jacob Garber Date: Wed, 7 Aug 2019 12:03:10 -0600 Subject: Makefile: Enable -Wimplicit-fallthrough Implicit fallthroughs are always a source of trouble, so let's get the compiler to catch them for us. Intentional fallthroughs can be marked using the /* fall through */ comment to silence this warning. BUG=none TEST=make clean && make runtests BRANCH=none Change-Id: I66a9edc810674a732c0530cd78b5aa8a2c37f562 Signed-off-by: Jacob Garber Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/vboot_reference/+/1742640 Reviewed-by: Patrick Georgi Reviewed-by: Julius Werner Commit-Queue: Manoj Gupta Tested-by: Patrick Georgi --- Makefile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Makefile b/Makefile index b81d312f..9167378d 100644 --- a/Makefile +++ b/Makefile @@ -142,7 +142,7 @@ COMMON_FLAGS := -pipe ${WERROR} -Wall -Wstrict-prototypes -Wtype-limits \ -Wundef -Wmissing-prototypes -Wno-trigraphs -Wredundant-decls \ -Wwrite-strings -Wstrict-aliasing -Wshadow -Wdate-time \ -Wno-address-of-packed-member -ffunction-sections -fdata-sections \ - ${DEBUG_FLAGS} + -Wimplicit-fallthrough ${DEBUG_FLAGS} # Note: FIRMWARE_ARCH is defined by the Chromium OS ebuild. ifeq (${FIRMWARE_ARCH}, arm) -- cgit v1.2.1