Red Hat Bugzilla – Bug 790979
Memory leaks and crashers found in python bindings in rpm-188.8.131.52-12.fc17 using gcc-with-cpychecker static analyzer
Last modified: 2012-05-08 08:10:05 EDT
Description of problem:
I've been writing an experimental static analysis tool to detect bugs commonly occurring within C Python extension modules:
I ran the latest version of the tool (in git master; post 0.9) on
rpm-184.108.40.206-12.fc17.src.rpm, and it reports various errors.
You can see a list of errors here, triaged into categories (from most significant to least significant):
Although the two bugs in the final category ("Returning (PyObject*)NULL without setting an exception") are false positives, I believe that all of the other bugs reported there are true errors.
There may of course be other bugs in my checker tool.
I submitted patches for these problems to rpm-maint in December 2011; see:
but I'm filing this here to ensure that the fixes make it into Fedora (and eventually RHEL).
Hope this is helpful; let me know if you need help reading the logs that the tool generates - I know that it could use some improvement.
Version-Release number of selected component (if applicable):
gcc-python-plugin post-0.9 git 073d390de53ef52136bd90e5ac06f1ef833d047d running the checker in an *f16* chroot
This package has changed ownership in the Fedora Package Database. Reassigning to the new owner of this component.
The entire patch set is part of rpm >= 4.10, in rawhide since late March, and the worser memleaks got backported to rpm 4.9.x in older Fedoras as well.