We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 4e1f599 commit 3127a3fCopy full SHA for 3127a3f
1 file changed
Programs/_testembed.c
@@ -2363,9 +2363,11 @@ do_tstate_ensure(void *arg)
2363
assert(res == 0);
2364
PyThreadState_Ensure(PyInterpreterState_Hold());
2365
2366
+ PyGILState_STATE gstate = PyGILState_Ensure();
2367
2368
res = PyRun_SimpleString(THREAD_CODE);
2369
PyThreadState_Release();
2370
+ PyGILState_Release(gstate);
2371
2372
2373
0 commit comments