]> git.ipfire.org Git - thirdparty/Python/cpython.git/commitdiff
Always use self->ob_type->tp_free when freeing an object.
authorJack Jansen <jack.jansen@cwi.nl>
Thu, 19 Dec 2002 23:34:40 +0000 (23:34 +0000)
committerJack Jansen <jack.jansen@cwi.nl>
Thu, 19 Dec 2002 23:34:40 +0000 (23:34 +0000)
Tools/bgen/bgen/bgenObjectDefinition.py

index 510b9b8442d3e65563b506742208dab2ead879c0..fd60d610aebff06dbfedde5130f7cba550dec789 100644 (file)
@@ -137,7 +137,7 @@ class ObjectDefinition(GeneratorGroup):
                if self.basetype:
                        Output("%s.tp_dealloc(self)", self.basetype)
                else:
-                       Output("PyObject_Del(self);")
+                       Output("self->ob_type->tp_free((PyObject *)self);")
                OutRbrace()
 
        def outputCleanupStructMembers(self):