Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit 9e29625

Browse files
committed
Patch #729300: Disable error message if Python is not built for threads.
1 parent fccac2e commit 9e29625

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

Python/pystate.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -264,7 +264,7 @@ PyThreadState_Swap(PyThreadState *new)
264264
to be used for a thread. Check this the best we can in debug
265265
builds.
266266
*/
267-
#if defined(Py_DEBUG)
267+
#if defined(Py_DEBUG) && defined(WITH_THREAD)
268268
if (new) {
269269
PyThreadState *check = PyGILState_GetThisThreadState();
270270
if (check && check != new)

0 commit comments

Comments
 (0)