Skip to content

Commit 5a48872

Browse files
committed
Stop calling PyEval_InitThreads
PyEval_InitThreads is depricated, since 3.7 it is not necessary to call it. Ref: https://docs.python.org/3/c-api/init.html#c.PyEval_InitThreads
1 parent dccfe90 commit 5a48872

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

cassandra/io/libevwrapper.c

+2
Original file line numberDiff line numberDiff line change
@@ -667,9 +667,11 @@ initlibevwrapper(void)
667667
if (PyModule_AddObject(module, "Timer", (PyObject *)&libevwrapper_TimerType) == -1)
668668
INITERROR;
669669

670+
#if PY_VERSION_HEX < 0x030700F0
670671
if (!PyEval_ThreadsInitialized()) {
671672
PyEval_InitThreads();
672673
}
674+
#endif
673675

674676
#if PY_MAJOR_VERSION >= 3
675677
return module;

0 commit comments

Comments
 (0)