Issue #10756: atexit normalizes the exception before displaying it.

This commit is contained in:
Victor Stinner 2011-01-05 03:54:25 +00:00
parent 29e762c941
commit 358e11d928
3 changed files with 11 additions and 0 deletions

View file

@ -72,6 +72,7 @@ atexit_callfuncs(void)
PyErr_Fetch(&exc_type, &exc_value, &exc_tb);
if (!PyErr_ExceptionMatches(PyExc_SystemExit)) {
PySys_WriteStderr("Error in atexit._run_exitfuncs:\n");
PyErr_NormalizeException(&exc_type, &exc_value, &exc_tb);
PyErr_Display(exc_type, exc_value, exc_tb);
}
}