ci: add Facebook Infer static analysis workflow#4
Open
agabhin wants to merge 1 commit into
Open
Conversation
8041043 to
4876dff
Compare
Replace the standalone infer.yml workflow with an infer-codechecker job in the existing codechecker.yml, consistent with how GCC and cppcheck analyzers are already integrated. Changes: - Add --infer flag to codechecker.sh with run_codechecker_infer() - Add infer-codechecker job to codechecker.yml - Simplify install_infer() to only download the binary (build deps are provided by --codechecker) - Remove standalone infer.yml and infer-suppressions.txt This lets developers reproduce Infer issues locally via: ./codechecker.sh --infer --codechecker --build-dir builddir Signed-off-by: Abhinav Agarwal <abhinavagarwal1996@gmail.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
.github/workflows/infer.ymlrunning Facebook Infer viacompile_commands.jsongenerated by meson/ninja--infermode toinstall-ubuntu-dependencies.shthat downloads Infer v1.2.0 from GitHub releases%dformat specifier forunsigned intfields inexample/printcap.c(caught by cppcheck)Why Infer
Infer's inter-procedural dataflow analysis targets exactly the bug classes that have appeared in libfuse historically:
fuse_get_context()null check fixfuse_ringfreed then stored)pthread_setspecific, mountpoint, pipe leaksfuse_daemonize()Unlike cppcheck/GCC analyzer, Infer tracks values across function call boundaries, which is how most of these bugs manifest.