提交 5cd072a3 authored 作者: Anthony Minessale's avatar Anthony Minessale

allow vars to be set containing vars from languages

上级 c3dcc603
......@@ -1823,7 +1823,7 @@ static JSBool session_set_variable(JSContext * cx, JSObject * obj, uintN argc, j
var = JS_GetStringBytes(JS_ValueToString(cx, argv[0]));
val = JS_GetStringBytes(JS_ValueToString(cx, argv[1]));
switch_channel_set_variable(channel, var, val);
switch_channel_set_variable_var_check(channel, var, val, SWITCH_FALSE);
*rval = BOOLEAN_TO_JSVAL(JS_TRUE);
} else {
*rval = BOOLEAN_TO_JSVAL(JS_FALSE);
......
......@@ -623,7 +623,7 @@ SWITCH_DECLARE(void) CoreSession::setVariable(char *var, char *val)
{
this_check_void();
sanity_check_noreturn;
switch_channel_set_variable(channel, var, val);
switch_channel_set_variable_var_check(channel, var, val, SWITCH_FALSE);
}
SWITCH_DECLARE(const char *)CoreSession::getVariable(char *var)
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论