[issue12483] CThunkObject_dealloc should call PyObject_GC_UnTrack?

2011-09-12 Thread Amaury Forgeot d'Arc
Amaury Forgeot d'Arc amaur...@gmail.com added the comment: I was going to say that the patch has no visible effect, since PyObject_GC_Del() calls something which has the same effect as PyObject_GC_Untrack... But the following code crashes the interpreter! And of course the patch fixes it...

[issue12483] CThunkObject_dealloc should call PyObject_GC_UnTrack?

2011-09-12 Thread Roundup Robot
Roundup Robot devn...@psf.upfronthosting.co.za added the comment: New changeset eb9f566fd8db by Amaury Forgeot d'Arc in branch '2.7': Issue #12483: ctypes: Fix a crash when the destruction of a callback http://hg.python.org/cpython/rev/eb9f566fd8db New changeset eae8e4ab0455 by Amaury Forgeot

[issue12483] CThunkObject_dealloc should call PyObject_GC_UnTrack?

2011-09-12 Thread Meador Inge
Meador Inge mead...@gmail.com added the comment: Heh, I was just about to upload another patch with your test case. Thanks for committing this Amaury. -- resolution: - fixed stage: patch review - committed/rejected status: open - closed ___ Python

[issue12483] CThunkObject_dealloc should call PyObject_GC_UnTrack?

2011-09-12 Thread Amaury Forgeot d'Arc
Amaury Forgeot d'Arc amaur...@gmail.com added the comment: Thanks for your help! I fear they are many other places like this one in CPython code. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue12483

[issue12483] CThunkObject_dealloc should call PyObject_GC_UnTrack?

2011-09-10 Thread Meador Inge
Meador Inge mead...@gmail.com added the comment: This patch seems reasonable, is consistent with the GC docs, and passed all regression tests. Can someone apply? -- nosy: +amaury.forgeotdarc, belopolsky, meadori stage: - patch review type: - behavior

[issue12483] CThunkObject_dealloc should call PyObject_GC_UnTrack?

2011-07-03 Thread Ryan Kelly
New submission from Ryan Kelly r...@rfk.id.au: According to the docs here: http://docs.python.org/c-api/gcsupport.html Any object that uses PyObject_GC_Track in its constructor must call PyObject_GC_UnTrack in its deallocator. The CThunkObject in _ctypes does the former but not the later.