diff options
author | Benjamin Otte <otte@redhat.com> | 2020-03-05 07:02:24 +0100 |
---|---|---|
committer | Benjamin Otte <otte@redhat.com> | 2020-03-05 08:14:37 +0100 |
commit | e356d59a92dfe24ff4a1c5b8300974f0427c90d0 (patch) | |
tree | 9a1e302fde600e7277d383d34ca11501f4b3afa8 /meson.build | |
parent | 4be479931666b65a615830d81d739894b5741076 (diff) | |
download | gtk+-e356d59a92dfe24ff4a1c5b8300974f0427c90d0.tar.gz |
build: Add -Wnull-dereference
Sprinkle various g_assert() around the code where gcc cannot figure out
on its own that a variable is not NULL and too much refactoring would be
needed to make it do that.
Also fix usage of g_assert_nonnull(x) to use g_assert(x) because the
first is not marked as G_GNUC_NORETURN because of course GTester
supports not aborting on aborts.
Diffstat (limited to 'meson.build')
-rw-r--r-- | meson.build | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/meson.build b/meson.build index dea88448b7..6fd7d68b45 100644 --- a/meson.build +++ b/meson.build @@ -251,6 +251,7 @@ elif cc.get_id() == 'gcc' or cc.get_id() == 'clang' '-Wmissing-include-dirs', '-Wmissing-noreturn', '-Wnested-externs', + '-Wnull-dereference', '-Wold-style-definition', '-Wpointer-arith', '-Wshadow', |