-
Notifications
You must be signed in to change notification settings - Fork 38
Open
Labels
bugSomething isn't workingSomething isn't working
Description
Environment
- OS Version: All
- Source build
Description
- Expected behavior:
make cppcheck
should return non-zero exit code if any error is detected. - Actual behavior: Cppcheck exits with return code of 0. See recent CI run in gz-sim for e.g. https://github.com/gazebosim/gz-sim/actions/runs/10464654584/job/28978620348 shows
/github/workspace/include/gz/sim/Conversions.hh:636:7: error: Found a exit path from function with non-void return type that has missing return statement [missingReturn]
Out::ConversionNotImplemented;
But the exit code was 0, so CI passed.
Looks like cppcheck requires the --error-exitcode=<n>
cmdline arg to be set in order to exit with a non-zero code in case of error. This will need to be set in cmake/GzCodeCheck.cmake to catch errors in CI.
Metadata
Metadata
Assignees
Labels
bugSomething isn't workingSomething isn't working
Type
Projects
Status
To do