Hello,
in Ivr, there is this initialization of the python interpreter:
void IvrFactory::init_python_interpreter(const string& script_path)
{
if(!Py_IsInitialized()){
add_env_path("PYTHONPATH",AmConfig::PlugInPath);
Py_Initialize();
}
PyEval_InitThreads();
set_sys_path(script_path);
import_ivr_builtins();
PyEval_SaveThread();
}
PyEval_InitThreads() acquires the GIL, and I suppose PyEval_SaveThread()
is there to release the GIL - but it also sets the interpreter thread
state to NULL and returns the current interpreter thread state
(http://www.python.org/doc/2.5.2/api/threads.html). Should this not be
simply PyEval_ReleaseLock() instead?
BR
Stefan
--
Stefan Sayer
VoIP Services
[email protected]
www.iptego.com
IPTEGO GmbH
Wittenbergplatz 1
10789 Berlin
Germany
Amtsgericht Charlottenburg, HRB 101010
Geschaeftsfuehrer: Alexander Hoffmann
_______________________________________________
Semsdev mailing list
[email protected]
http://lists.iptel.org/mailman/listinfo/semsdev