From 4c79a83e0c0cb6c68a63c116857a18307cafd9c9 Mon Sep 17 00:00:00 2001 From: "Kurt B. Kaiser" Date: Tue, 23 Nov 2004 18:06:08 +0000 Subject: Hye-Shik Chang's fix for Bug 875692. Improve signal handling, especially when using threads, by forcing an early re-execution of PyEval_EvalFrame() "periodic" code when things_to_do is not cleared by Py_MakePendingCalls(). M Misc/NEWS M Python/ceval.c --- Misc/NEWS | 13 +++++++++++++ Python/ceval.c | 6 ++++++ 2 files changed, 19 insertions(+) diff --git a/Misc/NEWS b/Misc/NEWS index 0bbfb88..9961639 100644 --- a/Misc/NEWS +++ b/Misc/NEWS @@ -4,6 +4,19 @@ Python News (editors: check NEWS.help for information about editing NEWS using ReST.) +What's New in Python 2.4 release candidate 2 +===================================================== + +*Release date: XX-NOV-2004* + +Core and builtins +----------------- + +- Bug 875692: Improve signal handling, especially when using threads, by + forcing an early re-execution of PyEval_EvalFrame() "periodic" code when + things_to_do is not cleared by Py_MakePendingCalls(). + + What's New in Python 2.4 (release candidate 1|beta 3) ===================================================== diff --git a/Python/ceval.c b/Python/ceval.c index 4d26a7a..85e3518 100644 --- a/Python/ceval.c +++ b/Python/ceval.c @@ -786,6 +786,12 @@ PyEval_EvalFrame(PyFrameObject *f) why = WHY_EXCEPTION; goto on_error; } + if (things_to_do) + /* MakePendingCalls() didn't succeed. + Force early re-execution of this + "periodic" code, possibly after + a thread switch */ + _Py_Ticker = 0; } #ifdef WITH_THREAD if (interpreter_lock) { -- cgit v0.12