-// Copyright (C) 2019-2021 CEA/DEN, EDF R&D, OPEN CASCADE
+// Copyright (C) 2019-2024 CEA, EDF, OPEN CASCADE
//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
PyDict_SetItemString(_globals,"socket",socket);
}
+void SALOME_CPythonHelper::allowPythonCallsFromDifferentThread() const
+{
+#if PY_VERSION_HEX < 0x03070000
+ PyEval_InitThreads(); /* Create (and acquire) the interpreter lock (for threads)*/
+#endif
+ PyEval_SaveThread(); /* Release the thread state */
+}
+
void SALOME_CPythonHelper::registerToSalomePiDict(const std::string& processName, long pid) const
{
AutoGIL agil;