Mercurial > cpython-lru_cache-weakref
diff Python/pystate.c @ 41131:66f265ac4ec4 2.5
Bug #742342: make Python stop segfaulting on infinitely-recursive reload()s. Fixed by patch #922167.
Backported from r54291.
| author | Collin Winter <collinw@gmail.com> |
|---|---|
| date | Mon, 12 Mar 2007 16:49:23 +0000 |
| parents | 603cde5ed1eb |
| children | eefe4450f773 eb2eafda29b7 |
line wrap: on
line diff
--- a/Python/pystate.c Mon Mar 12 16:15:17 2007 +0000 +++ b/Python/pystate.c Mon Mar 12 16:49:23 2007 +0000 @@ -68,6 +68,7 @@ Py_FatalError("Can't initialize threads for interpreter"); #endif interp->modules = NULL; + interp->modules_reloading = NULL; interp->sysdict = NULL; interp->builtins = NULL; interp->tstate_head = NULL; @@ -107,6 +108,7 @@ Py_CLEAR(interp->codec_search_cache); Py_CLEAR(interp->codec_error_registry); Py_CLEAR(interp->modules); + Py_CLEAR(interp->modules_reloading); Py_CLEAR(interp->sysdict); Py_CLEAR(interp->builtins); }
