[Freeswitch-svn] [commit] r7877 - freeswitch/trunk/src/mod/languages/mod_spidermonkey
Freeswitch SVN
mikej at freeswitch.org
Wed Mar 12 03:03:12 EDT 2008
Author: mikej
Date: Wed Mar 12 03:03:11 2008
New Revision: 7877
Modified:
freeswitch/trunk/src/mod/languages/mod_spidermonkey/mod_spidermonkey.c
Log:
let session.ready property work without throwing exception after a failed originate
Modified: freeswitch/trunk/src/mod/languages/mod_spidermonkey/mod_spidermonkey.c
==============================================================================
--- freeswitch/trunk/src/mod/languages/mod_spidermonkey/mod_spidermonkey.c (original)
+++ freeswitch/trunk/src/mod/languages/mod_spidermonkey/mod_spidermonkey.c Wed Mar 12 03:03:11 2008
@@ -1969,9 +1969,7 @@
{
struct js_session *jss = JS_GetPrivate(cx, obj);
- METHOD_SANITY_CHECK();
-
- *rval = BOOLEAN_TO_JSVAL(switch_channel_ready(switch_core_session_get_channel(jss->session)) ? JS_TRUE : JS_FALSE);
+ *rval = BOOLEAN_TO_JSVAL((jss && jss->session && switch_channel_ready(switch_core_session_get_channel(jss->session))) ? JS_TRUE : JS_FALSE);
return JS_TRUE;
}
More information about the Freeswitch-svn
mailing list