[bind10-dev] cppcheck monthly report

Jeremy C. Reed jreed at isc.org
Mon Jul 19 13:15:42 UTC 2010


I am going to automate a monthly email to send the cppcheck output.
The latest output is always at 
http://bind10.isc.org/~tester/LATEST_CPPCHECK

I know some of you already use it.

A description of the tool is: "cppcheck is a tool for static C/C++ code 
analysis intended to complement the checking of the compiler.  It checks 
for memory leaks, mismatching allocation-deallocation, buffer overrun, 
unused functions, coding style, and much more."

I understand there may be misleading reports. If you know of anything 
that should be ignored or removed from the report, please let me know.

The following is the report for today:

[src/bin/auth/asio_link.cc:102]: (style) Member variable not initialized in the constructor 'TCPClient::data_'

[src/bin/auth/asio_link.cc:289]: (style) Member variable not initialized in the constructor 'UDPServer::data_'

[src/lib/cc/session.cc:76]: (style) Unused private function 'SessionImpl::internalRead'

[src/lib/config/tests/ccsession_unittests.cc:36]: (style) Function parameter 'name' is passed by value. It could be passed by reference instead.

[src/lib/config/tests/module_spec_unittests.cc:28]: (style) Function parameter 'name' is passed by value. It could be passed by reference instead.

[src/lib/datasrc/data_source.cc:1155]: (possible style) Pre-Incrementing variable 'it' is preferred to Post-Incrementing

[src/lib/dns/python/message_python.cc:1195]: (style) Redundant condition. It is safe to deallocate a NULL pointer

[src/lib/dns/python/rrclass_python.cc:204]: (style) Redundant condition. It is safe to deallocate a NULL pointer

[src/lib/dns/python/rrttl_python.cc:202]: (style) Redundant condition. It is safe to deallocate a NULL pointer

[src/lib/dns/python/rrtype_python.cc:242]: (style) Redundant condition. It is safe to deallocate a NULL pointer

[src/lib/dns/rdata/generic/nsec3_50.cc:99]: (style) The scope of the variable code can be reduced

[src/lib/dns/rdata/generic/nsec_47.cc:66]: (style) The scope of the variable code can be reduced

[src/lib/dns/python/libdns_python.cc:1]: (style) The function 'PyInit_libdns_python' is never used

[src/lib/xfr/fdshare_python.cc:1]: (style) The function 'PyInit_libxfr_python' is never used

[src/lib/dns/sha1.cc:1]: (style) The function 'SHA1FinalBits' is never used

[:1]: (style) The function 'caseStringEqual' is never used

[src/lib/dns/tests/unittest_util.cc:1]: (style) The function 'matchName' is never used

[src/lib/dns/tests/unittest_util.cc:1]: (style) The function 'matchWireData' is never used





More information about the bind10-dev mailing list