From: Miss Islington (bot) <31488909+miss-islington@users.noreply.github.com> Date: Thu, 3 Oct 2024 10:45:25 +0000 (+0200) Subject: [3.12] gh-115145: Update documentation about ``PyThreadState_DeleteCurrent`` (gh... X-Git-Tag: v3.12.8~258 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=58f7763b88d4e81662b9d212f6beddcb42437fe3;p=thirdparty%2FPython%2Fcpython.git [3.12] gh-115145: Update documentation about ``PyThreadState_DeleteCurrent`` (gh-124920) (gh-124931) gh-115145: Update documentation about ``PyThreadState_DeleteCurrent`` (gh-124920) (cherry picked from commit 9eeb21bf761070649bf8d78976a62dabb6d67a99) Co-authored-by: Donghee Na --- diff --git a/Doc/c-api/init.rst b/Doc/c-api/init.rst index 8b7b28ae3192..bec075038f06 100644 --- a/Doc/c-api/init.rst +++ b/Doc/c-api/init.rst @@ -1269,7 +1269,7 @@ All of the following functions must be called after :c:func:`Py_Initialize`. .. c:function:: void PyThreadState_DeleteCurrent(void) Destroy the current thread state and release the global interpreter lock. - Like :c:func:`PyThreadState_Delete`, the global interpreter lock need not + Like :c:func:`PyThreadState_Delete`, the global interpreter lock must be held. The thread state must have been reset with a previous call to :c:func:`PyThreadState_Clear`.