From 88aa0186df73d992dc807adcea9121ca96d70398 Mon Sep 17 00:00:00 2001 From: Nicholas Sielicki Date: Sun, 29 Sep 2024 20:58:33 -0700 Subject: [PATCH] feat(build): enable -Wnull-dereference We get this for free, likely fixed in #627 or with some of the -fanalyzer fixes. Enable -Wnull-dereference whenever -Werror is enabled. Signed-off-by: Nicholas Sielicki --- configure.ac | 2 ++ 1 file changed, 2 insertions(+) diff --git a/configure.ac b/configure.ac index 1fc3b1a09..55d4a877c 100644 --- a/configure.ac +++ b/configure.ac @@ -198,6 +198,8 @@ dnl warn on security issues around functions that format output (ie printf) ADD_PICKY_FLAGS([-Wformat=2]) dnl warn for potential performance problem casts ADD_PICKY_FLAGS([-Wcast-align]) +dnl warn if a null dereference is detected +ADD_PICKY_FLAGS([-Wnull-dereference]) dnl warn when a case statement is missing a break or a line that contains a dnl comment before the next case.