summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorGuido van Rossum <guido@python.org>2001-01-23 01:47:18 (GMT)
committerGuido van Rossum <guido@python.org>2001-01-23 01:47:18 (GMT)
commit2528b19a86ed8d3ed26114c414a7a312fa85e72d (patch)
treebd931674aa0d2fc306046c0e97669ac1b35f45da
parent2975786decbe2358b088a6200914d7c0a2818e72 (diff)
downloadcpython-2528b19a86ed8d3ed26114c414a7a312fa85e72d.zip
cpython-2528b19a86ed8d3ed26114c414a7a312fa85e72d.tar.gz
cpython-2528b19a86ed8d3ed26114c414a7a312fa85e72d.tar.bz2
Use PyThreadState_DeleteCurrent() instead of PyThreadState_Delete()
and PyEval_ReleaseThread(). This fixes SF bug #125673 PyThreadState_Delete: invalid tstate (Unix only?).
-rw-r--r--Modules/threadmodule.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/Modules/threadmodule.c b/Modules/threadmodule.c
index e0afde5..48f1f36 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();
}