After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 670297 - Memory leaks found in bluefish-2.2.1-2.fc17 using gcc-with-cpychecker static analyzer
Memory leaks found in bluefish-2.2.1-2.fc17 using gcc-with-cpychecker static ...
Status: RESOLVED FIXED
Product: bluefish
Classification: Other
Component: application
2.2.1
Other Linux
: Normal normal
: 2.2.4
Assigned To: Bluefish Maintainer(s)
Bluefish Maintainer(s)
Depends on:
Blocks:
 
 
Reported: 2012-02-17 16:05 UTC by Paul Howarth
Modified: 2013-02-05 21:45 UTC
See Also:
GNOME target: ---
GNOME version: ---



Description Paul Howarth 2012-02-17 16:05:23 UTC
Dave Malcolm, the python maintainer for the Fedora Linux distribution has been writing an experimental static analysis tool to detect bugs commonly occurring within C Python extension modules:

  https://fedorahosted.org/gcc-python-plugin/
  http://gcc-python-plugin.readthedocs.org/en/latest/cpychecker.html
  http://fedoraproject.org/wiki/Features/StaticAnalysisOfPythonRefcounts

He ran the latest version of the tool on the Fedora bluefish package (2.2.1), and it reported various errors.

You can see a list of errors here, triaged into categories (from most
significant to least significant):
http://fedorapeople.org/~dmalcolm/gcc-python-plugin/2012-02-16/bluefish-2.2.1-2.fc17/

He manually inspected the results, and the two memory leaks in "Reference leaks"
appear to be genuine bugs:

  zencoding.c:zencoding_run_action:ob_refcnt of '*ptr' is 1 too high
(memory leak in error handling)

  zeneditor-interface.c:get_caret_placeholder:ob_refcnt of
'*pcaret_placeholder' is 1 too high
(memory leak under normal operation, I think)

The other reported errors seem to be unlikely to happen in practice.

There may of course be other bugs in the checker tool.

Hope this is helpful; let him know (https://bugzilla.redhat.com/show_bug.cgi?id=791186) if you need help reading the logs that the
tool generates - he knows that it could use some improvement.
Comment 1 Olivier Sessink 2012-02-19 20:38:15 UTC
cool stuff :)

thanks, fixed all the bugs (I think)