even more lang stuff

git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@9063 d0543943-73ff-0310-b7d9-9358b9ac24b2
This commit is contained in:
Anthony Minessale
2008-07-16 21:06:14 +00:00
parent 920ef82cb3
commit df5afbcacd
16 changed files with 280 additions and 42 deletions
@@ -10,7 +10,7 @@ Session::Session():CoreSession()
py_init_vars();
}
Session::Session(char *uuid):CoreSession(uuid)
Session::Session(char *nuuid, CoreSession *a_leg):CoreSession(nuuid, a_leg)
{
py_init_vars();
}
@@ -59,6 +59,9 @@ bool Session::begin_allow_threads()
if (!TS) {
TS = PyEval_SaveThread();
if (channel) {
switch_channel_set_private(channel, "SwapInThreadState", TS);
}
return true;
}
@@ -75,6 +78,10 @@ bool Session::end_allow_threads()
PyEval_RestoreThread(TS);
TS = NULL;
if (channel) {
switch_channel_set_private(channel, "SwapInThreadState", NULL);
}
do_hangup_hook();
return true;