diff options
author | Serhiy Storchaka <storchaka@gmail.com> | 2014-02-09 13:46:20 +0200 |
---|---|---|
committer | Serhiy Storchaka <storchaka@gmail.com> | 2014-02-09 13:46:20 +0200 |
commit | dfe98a102ec8723d750f78ecda08a7adb9360eb1 (patch) | |
tree | f8aea8fb3d74be18ed67a2f4e0a355ad9beb42d8 /Python/sysmodule.c | |
parent | 2623c8c23cead505a78ec416072223552e94727e (diff) | |
parent | 505ff755d704c73ac613d3e8fed02c79c6ae555a (diff) | |
download | cpython-git-dfe98a102ec8723d750f78ecda08a7adb9360eb1.tar.gz |
Issue #20437: Fixed 22 potential bugs when deleting objects references.
Diffstat (limited to 'Python/sysmodule.c')
-rw-r--r-- | Python/sysmodule.c | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/Python/sysmodule.c b/Python/sysmodule.c index 976d5a0c37..9ec3bfa07b 100644 --- a/Python/sysmodule.c +++ b/Python/sysmodule.c @@ -430,8 +430,7 @@ trace_trampoline(PyObject *self, PyFrameObject *frame, result = call_trampoline(callback, frame, what, arg); if (result == NULL) { PyEval_SetTrace(NULL, NULL); - Py_XDECREF(frame->f_trace); - frame->f_trace = NULL; + Py_CLEAR(frame->f_trace); return -1; } if (result != Py_None) { |