diff options
author | Guido van Rossum <guido@python.org> | 2013-05-10 15:47:42 (GMT) |
---|---|---|
committer | Guido van Rossum <guido@python.org> | 2013-05-10 15:47:42 (GMT) |
commit | 6832c81d5d2d730c38bab001e0c1b4b0569dd5ef (patch) | |
tree | f4725451768bda1987adf4eca22d2e232018fd9f /Objects | |
parent | 8c01ffa6ede5da92ab144ad2ea609a96e308b1e6 (diff) | |
download | cpython-6832c81d5d2d730c38bab001e0c1b4b0569dd5ef.zip cpython-6832c81d5d2d730c38bab001e0c1b4b0569dd5ef.tar.gz cpython-6832c81d5d2d730c38bab001e0c1b4b0569dd5ef.tar.bz2 |
#17927: Keep frame from referencing cell-ified arguments.
Diffstat (limited to 'Objects')
-rw-r--r-- | Objects/typeobject.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/Objects/typeobject.c b/Objects/typeobject.c index aa67af8..e418a3a 100644 --- a/Objects/typeobject.c +++ b/Objects/typeobject.c @@ -6510,6 +6510,10 @@ super_init(PyObject *self, PyObject *args, PyObject *kwds) return -1; } obj = f->f_localsplus[0]; + if (obj != NULL && PyCell_Check(obj)) { + /* It might be a cell. See cell var initialization in ceval.c. */ + obj = PyCell_GET(obj); + } if (obj == NULL) { PyErr_SetString(PyExc_RuntimeError, "super(): arg[0] deleted"); |