Cppcheck is a tool for static C/C++ code analysis. It tries to
detect bugs that your compiler does not see. It checks for: memory leaks,
mismatching allocations-deallocations, buffer overruns, and many more.

Cppcheck is versatile. You can check non-standard code that includes
various compiler extensions, inline assembly code, etc.

The goal is to have no false positives.
