Roundup Robot devnull@devnull added the comment:
New changeset 52fb7dc721ed by Daniel Stutzbach in branch '3.2':
#11335: Fix memory leak after key function failure in sort
http://hg.python.org/cpython/rev/52fb7dc721ed
New changeset 18e43c6acfff by Daniel Stutzbach in branch 'default':
#11335:
Changes by Daniel Stutzbach stutzb...@google.com:
--
resolution: - fixed
stage: patch review - committed/rejected
status: open - closed
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue11335
Daniel Stutzbach stutzb...@google.com added the comment:
I checked in a fix to 3.3 just before the transition to hg. I confess that
I've been procrastinating on getting hg set up properly, which is why I haven't
gotten to checking this in to 3.2.
Georg, if I get this in by Wednesday, will
Georg Brandl ge...@python.org added the comment:
Sure, Wednesday will be fine.
--
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue11335
___
___
Raymond Hettinger rhettin...@users.sourceforge.net added the comment:
Is there a way to test this?
--
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue11335
___
Antoine Pitrou pit...@free.fr added the comment:
Valgrind perhaps?
If the keys container was a list or tuple it would simply take a refleak run
of the test suite.
--
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue11335
Daniel Stutzbach stutzb...@google.com added the comment:
I'm not sure. What infrastructure do we have to leaked memory that was
allocated with PyMem_MALLOC?
--
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue11335
Daniel Stutzbach stutzb...@google.com added the comment:
I meant to *detect* leaked memory, of course. :-)
--
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue11335
___
Daniel Stutzbach stutzb...@google.com added the comment:
I played around with this a little. That code path doesn't appear to be
exercised during the existing unit tests. I'll add a test so the leak at least
shows up when the tests are run under valgrind.
--
New submission from Daniel Stutzbach stutzb...@google.com:
In list.sort, if a key function throws an exception, the memory to store the
keys is never freed. I introduced the bug in r86937. I'll upload a patch for
review shortly.
--
assignee: stutzbach
components: Interpreter Core
Daniel Stutzbach stutzb...@google.com added the comment:
Below is a link to the code where leak occurs and the patch goes:
http://svn.python.org/view/python/branches/py3k/Objects/listobject.c?view=markuppathrev=88554#l1944
--
keywords: +3.2regression, needs review, patch
Added file:
Benjamin Peterson benja...@python.org added the comment:
LGTM
--
nosy: +benjamin.peterson
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue11335
___
12 matches
Mail list logo