From 2528b19a86ed8d3ed26114c414a7a312fa85e72d Mon Sep 17 00:00:00 2001 From: Guido van Rossum Date: Tue, 23 Jan 2001 01:47:18 +0000 Subject: [PATCH] Use PyThreadState_DeleteCurrent() instead of PyThreadState_Delete() and PyEval_ReleaseThread(). This fixes SF bug #125673 PyThreadState_Delete: invalid tstate (Unix only?). --- Modules/threadmodule.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/Modules/threadmodule.c b/Modules/threadmodule.c index e0afde5ea9e..48f1f36cdac 100644 --- a/Modules/threadmodule.c +++ b/Modules/threadmodule.c @@ -204,8 +204,7 @@ t_bootstrap(void *boot_raw) else Py_DECREF(res); PyThreadState_Clear(tstate); - PyEval_ReleaseThread(tstate); - PyThreadState_Delete(tstate); + PyThreadState_DeleteCurrent(); PyThread_exit_thread(); }