Fix subtle bug in cleanup code in PyErr_NormalizeException(), detected
by Marc Lemburg. There's a path through the code where *val is NULL, but value isn't, and value should be DECREF'ed.
This commit is contained in:
parent
a2e268aa40
commit
19b55f2d17
@ -219,8 +219,8 @@ PyErr_NormalizeException(exc, val, tb)
|
||||
*val = value;
|
||||
return;
|
||||
finally:
|
||||
Py_DECREF(*exc);
|
||||
Py_DECREF(*val);
|
||||
Py_DECREF(type);
|
||||
Py_DECREF(value);
|
||||
Py_XDECREF(*tb);
|
||||
PyErr_Fetch(exc, val, tb);
|
||||
/* normalize recursively */
|
||||
|
Loading…
x
Reference in New Issue
Block a user