This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author theller
Recipients theller
Date 2008-11-26.08:36:04
SpamBayes Score 0.00013114615
Marked as misclassified No
Message-id <1227688566.82.0.912024341466.issue4433@psf.upfronthosting.co.za>
In-reply-to
Content
The following code, which only works on Windows, crashes with an access
violation somewhere in the garbage collector in a debug build:

>>> import _ctypes
[43470 refs]
>>> _ctypes.COMError(1, 2, 3)

The problem is that the PyComError_Type's tp_flags contains
Py_TPFLAGS_HAVE_GC although the tp_traverse slot is NULL.

The attached patch removes the Py_TPFLAGS_HAVE_GC which is not necessary
at all because a PyComError_Type instance (normally) only contains
simple objects (strings, numbers, None, and a tuple of strings, numbers,
and None), so no reference cycles should be possible.
History
Date User Action Args
2008-11-26 08:36:06thellersetrecipients: + theller
2008-11-26 08:36:06thellersetmessageid: <1227688566.82.0.912024341466.issue4433@psf.upfronthosting.co.za>
2008-11-26 08:36:05thellerlinkissue4433 messages
2008-11-26 08:36:05thellercreate