mirror of
https://github.com/python/cpython.git
synced 2026-05-07 05:01:13 -04:00
bpo-43660: Fix crash when displaying exceptions with custom values for sys.stderr (GH-25075)
This commit is contained in:
+2
-1
@@ -1082,8 +1082,9 @@ PyErr_Display(PyObject *exception, PyObject *value, PyObject *tb)
|
||||
if (file == Py_None) {
|
||||
return;
|
||||
}
|
||||
|
||||
Py_INCREF(file);
|
||||
_PyErr_Display(file, exception, value, tb);
|
||||
Py_DECREF(file);
|
||||
}
|
||||
|
||||
PyObject *
|
||||
|
||||
Reference in New Issue
Block a user