]> git.ipfire.org Git - thirdparty/Python/cpython.git/commitdiff
Move exception finalisation later in the shutdown process - this
authorAnthony Baxter <anthonybaxter@gmail.com>
Tue, 29 Mar 2005 12:32:50 +0000 (12:32 +0000)
committerAnthony Baxter <anthonybaxter@gmail.com>
Tue, 29 Mar 2005 12:32:50 +0000 (12:32 +0000)
fixes the crash seen in bug #1165761

Misc/NEWS
Python/pythonrun.c

index 41e91aefa7a7b6067f2932ab06b8b1207c7dd7dd..7ecddce5486ddccf78c89f2352b32a41ecd7d022 100644 (file)
--- a/Misc/NEWS
+++ b/Misc/NEWS
@@ -4,6 +4,17 @@ Python News
 
 (editors: check NEWS.help for information about editing NEWS using ReST.)
 
+What's New in Python 2.4.1 final?
+=================================
+
+*Release date: 30-MAR-2005*
+
+Core and builtins
+-----------------
+
+- Move exception finalisation later in the shutdown process - this 
+  fixes the crash seen in bug #1165761
+
 What's New in Python 2.4.1c2?
 =============================
 
index e9f4765a1e11138ab46737620db31091eb85c071..50bb20d15c431647517e39dad229a7e8263df7f2 100644 (file)
@@ -392,13 +392,6 @@ Py_Finalize(void)
                _Py_PrintReferences(stderr);
 #endif /* Py_TRACE_REFS */
 
-       /* Now we decref the exception classes.  After this point nothing
-          can raise an exception.  That's okay, because each Fini() method
-          below has been checked to make sure no exceptions are ever
-          raised.
-       */
-       _PyExc_Fini();
-
        /* Cleanup auto-thread-state */
 #ifdef WITH_THREAD
        _PyGILState_Fini();
@@ -407,6 +400,14 @@ Py_Finalize(void)
        /* Clear interpreter state */
        PyInterpreterState_Clear(interp);
 
+       /* Now we decref the exception classes.  After this point nothing
+          can raise an exception.  That's okay, because each Fini() method
+          below has been checked to make sure no exceptions are ever
+          raised.
+       */
+
+       _PyExc_Fini();
+
        /* Delete current thread */
        PyThreadState_Swap(NULL);
        PyInterpreterState_Delete(interp);