Mercurial > cpython-lru_cache-weakref
diff Python/symtable.c @ 52705:33eb1697c382
fix ref leaks
| author | Benjamin Peterson <benjamin@python.org> |
|---|---|
| date | Thu, 02 Apr 2009 01:50:37 +0000 |
| parents | 2b436310fc8b |
| children | bc15b483d384 |
line wrap: on
line diff
--- a/Python/symtable.c Thu Apr 02 01:14:45 2009 +0000 +++ b/Python/symtable.c Thu Apr 02 01:50:37 2009 +0000 @@ -766,6 +766,7 @@ if (PyNumber_InPlaceOr(newfree, allfree) < 0) goto error; + Py_DECREF(newfree); /* Check if any local variables must be converted to cell variables */ if (ste->ste_type == FunctionBlock && !analyze_cells(scopes, newfree, @@ -824,6 +825,7 @@ if (!analyze_block(entry, temp_bound, temp_free, temp_global)) goto error; success = PyNumber_InPlaceOr(child_free, temp_free) >= 0; + Py_DECREF(child_free); success = 1; error: Py_XDECREF(temp_bound);
