diff options
author | Victor Stinner <vstinner@redhat.com> | 2019-05-04 15:48:05 (GMT) |
---|---|---|
committer | GitHub <noreply@github.com> | 2019-05-04 15:48:05 (GMT) |
commit | c664b342a47e4b4650706d07e3e40a295e3a4407 (patch) | |
tree | 960378ef676a7dc621be03f0b7744ce73a0948c0 /Python | |
parent | 6b5b013bcc22a27d6231c2796882e44ddb42be67 (diff) | |
download | cpython-c664b342a47e4b4650706d07e3e40a295e3a4407.zip cpython-c664b342a47e4b4650706d07e3e40a295e3a4407.tar.gz cpython-c664b342a47e4b4650706d07e3e40a295e3a4407.tar.bz2 |
bpo-36475: Make PyThread_exit_thread with _Py_NO_RETURN (GH-13068)
Diffstat (limited to 'Python')
-rw-r--r-- | Python/ceval.c | 1 | ||||
-rw-r--r-- | Python/thread_nt.h | 2 | ||||
-rw-r--r-- | Python/thread_pthread.h | 2 |
3 files changed, 2 insertions, 3 deletions
diff --git a/Python/ceval.c b/Python/ceval.c index 8ae273e..e616a3f 100644 --- a/Python/ceval.c +++ b/Python/ceval.c @@ -211,7 +211,6 @@ exit_thread_if_finalizing(PyThreadState *tstate) if (_Py_IsFinalizing() && !_Py_CURRENTLY_FINALIZING(tstate)) { drop_gil(tstate); PyThread_exit_thread(); - Py_UNREACHABLE(); } } diff --git a/Python/thread_nt.h b/Python/thread_nt.h index fdb192b..5e00c35 100644 --- a/Python/thread_nt.h +++ b/Python/thread_nt.h @@ -227,7 +227,7 @@ PyThread_get_thread_ident(void) return GetCurrentThreadId(); } -void +void _Py_NO_RETURN PyThread_exit_thread(void) { dprintf(("%lu: PyThread_exit_thread called\n", PyThread_get_thread_ident())); diff --git a/Python/thread_pthread.h b/Python/thread_pthread.h index 25f58d9..1f4f36d 100644 --- a/Python/thread_pthread.h +++ b/Python/thread_pthread.h @@ -302,7 +302,7 @@ PyThread_get_thread_ident(void) return (unsigned long) threadid; } -void +void _Py_NO_RETURN PyThread_exit_thread(void) { dprintf(("PyThread_exit_thread called\n")); |