[Freeswitch-svn] [commit] r4835 - freeswitch/trunk/src/mod/languages/mod_spidermonkey

Freeswitch SVN anthm at freeswitch.org
Mon Apr 2 19:34:58 EDT 2007


Author: anthm
Date: Mon Apr  2 19:34:58 2007
New Revision: 4835

Modified:
   freeswitch/trunk/src/mod/languages/mod_spidermonkey/mod_spidermonkey.c

Log:
update

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	Mon Apr  2 19:34:58 2007
@@ -2663,7 +2663,6 @@
 		for (y = 0; y < argc; y++) {
 			snprintf(buf, sizeof(buf), "~argv[%d] = \"%s\";", x++, argv[y]);
 			eval_some_js(buf, cx, javascript_global_object, &rval);
-
 		}
 	}
 
@@ -2764,10 +2763,13 @@
 	if (account) {
 		char *text;
 
-		text = switch_mprintf("mwi.js %s", account);
+		text = switch_mprintf("%s%smwi.js", SWITCH_GLOBAL_dirs.script_dir, SWITCH_PATH_SEPARATOR);
 		assert(text != NULL);
 
-		js_thread_launch(text);
+		if (switch_file_exists(text) == SWITCH_STATUS_SUCCESS) {
+			js_thread_launch(text);
+		}
+
 		free(text);
 	}
 



More information about the Freeswitch-svn mailing list