提交 f7d55aec authored 作者: Anthony Minessale's avatar Anthony Minessale

treat app::arg syntax in execute_on_answer as a broadcast request

git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@13400 d0543943-73ff-0310-b7d9-9358b9ac24b2
上级 110535cf
...@@ -1893,12 +1893,17 @@ SWITCH_DECLARE(switch_status_t) switch_channel_perform_mark_answered(switch_chan ...@@ -1893,12 +1893,17 @@ SWITCH_DECLARE(switch_status_t) switch_channel_perform_mark_answered(switch_chan
char *arg = NULL; char *arg = NULL;
app = switch_core_session_strdup(channel->session, var); app = switch_core_session_strdup(channel->session, var);
if ((arg = strchr(app, ' '))) { if ((arg = strchr(app, ':')) && *(arg+1) == ':') {
*arg++ = '\0'; switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_DEBUG, "%s execute on answer: %s (BROADCAST)\n", channel->name, app);
switch_ivr_broadcast(switch_core_session_get_uuid(channel->session), app, SMF_NONE);
} else {
if ((arg = strchr(app, ' '))) {
*arg++ = '\0';
}
switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_DEBUG, "%s execute on answer: %s(%s)\n", channel->name, app, switch_str_nil(arg));
switch_core_session_execute_application(channel->session, app, arg);
} }
switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_DEBUG, "%s execute on answer: %s(%s)", channel->name, app, switch_str_nil(arg));
switch_core_session_execute_application(channel->session, app, arg);
} }
switch_channel_audio_sync(channel); switch_channel_audio_sync(channel);
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论