Unverified Commit e170e6f2 authored by Guilhem Saurel's avatar Guilhem Saurel Committed by GitHub
Browse files

Merge pull request #81 from nim65s/topic/py39

interpreter: fix deprecation for python 3.9
parents 84df690f 4982119a
Pipeline #15891 passed with stage
in 13 minutes and 54 seconds
......@@ -69,7 +69,9 @@ Interpreter::Interpreter() {
dlopen(PYTHON_LIBRARY, RTLD_LAZY | RTLD_GLOBAL);
#endif
Py_Initialize();
#if PY_MAJOR_VERSION < 3 || PY_MINOR_VERSION < 7
PyEval_InitThreads();
#endif
mainmod_ = PyImport_AddModule("__main__");
Py_INCREF(mainmod_);
globals_ = PyModule_GetDict(mainmod_);
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment