Lots and lots of potential bugs detected by GCC 14 analyzer

Stephen Hemminger stephen at networkplumber.org
Mon Nov 11 00:16:44 CET 2024


If -fanalyzer is added to config/meson.build than compiler finds lots of potential
problems. (Think of it as free version of Coverity).

The output is quite verbose.
Is it worth putting large N of new bugs into bugzilla or maybe maintainers could take a look.

Full build output is 12M so attaching it.


Quick hack to enable is.

diff --git a/config/meson.build b/config/meson.build
index 5095d2fbcb..43c2a6d97b 100644
--- a/config/meson.build
+++ b/config/meson.build
@@ -308,6 +308,8 @@ endif
 # -Wall is added by default at warning level 1, and -Wextra
 # at warning level 2 (DPDK default)
 warning_flags = [
+    '-fanalyzer',
+
         # additional warnings in alphabetical order
         '-Wcast-qual',
         '-Wdeprecated',
~/DPDK/main $ 
-------------- next part --------------
A non-text attachment was scrubbed...
Name: build.out.gz
Type: application/gzip
Size: 843401 bytes
Desc: not available
URL: <http://mails.dpdk.org/archives/dev/attachments/20241110/c0c893c5/attachment-0001.gz>


More information about the dev mailing list