From a703217eaf4075e9720d4247351e1dfc4f553772 Mon Sep 17 00:00:00 2001 From: Simon Feltman Date: Fri, 19 Apr 2013 06:37:24 -0700 Subject: Remove half implemented GC in PyGIBaseInfo, PyGIStruct, and PyGIBoxed Remove half implemented GC tracking from PyGIBaseInfo as it was not needed (the implemented was also missing usage of PyObject_GC_New/Track). Ensure weakref list for PyGIBaseInfo is initialized to NULL and cleared properly. Remove invalid calls to PyObject_GC_UnTrack and PyObject_ClearWeakRefs for both PyGIStruct and PyGIBoxed as these types were not being advertised as GC aware with Py_TPFLAGS_HAVE_GC. https://bugzilla.gnome.org/show_bug.cgi?id=677091 --- gi/pygi-struct.c | 4 ---- 1 file changed, 4 deletions(-) (limited to 'gi/pygi-struct.c') diff --git a/gi/pygi-struct.c b/gi/pygi-struct.c index eace77c1..29ea38e8 100644 --- a/gi/pygi-struct.c +++ b/gi/pygi-struct.c @@ -34,10 +34,6 @@ _struct_dealloc (PyGIStruct *self) (PyObject *) self, &PyGIStructInfo_Type); - PyObject_GC_UnTrack ( (PyObject *) self); - - PyObject_ClearWeakRefs ( (PyObject *) self); - if (info != NULL && g_struct_info_is_foreign ( (GIStructInfo *) info)) { pygi_struct_foreign_release (info, ( (PyGPointer *) self)->pointer); } else if (self->free_on_dealloc) { -- cgit v1.2.1