diff Python/Python-ast.c @ 77998:048d8d9aecf1

Issue #15291: Fix a memory leak where AST nodes where not properly deallocated.
author Antoine Pitrou <solipsis@pitrou.net>
date Sun, 08 Jul 2012 12:43:32 +0200
parents c18a1a82bb07
children 85cccc38d01c
line wrap: on
line diff
--- a/Python/Python-ast.c	Sun Jul 08 12:01:27 2012 +0200
+++ b/Python/Python-ast.c	Sun Jul 08 12:43:32 2012 +0200
@@ -464,6 +464,7 @@
 ast_dealloc(AST_object *self)
 {
     Py_CLEAR(self->dict);
+    Py_TYPE(self)->tp_free(self);
 }
 
 static int