提交 33a3bcf5 authored 作者: Anthony Minessale's avatar Anthony Minessale

add disposition to monitor_early_media

git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@11437 d0543943-73ff-0310-b7d9-9358b9ac24b2
上级 d9bb4dcc
......@@ -248,11 +248,22 @@ static switch_bool_t monitor_callback(switch_core_session_t *session, const char
if (app) {
switch_channel_t *channel = switch_core_session_get_channel(session);
if (!strcmp(app, "fail")) {
const char *bd = switch_channel_get_variable(channel, "monitor_fail_dispo");
if (!bd) {
bd = "monitor_early_media_fail";
}
switch_channel_set_variable(channel, "originate_disposition", bd);
switch_channel_hangup(channel, data ? switch_channel_str2cause(data) : SWITCH_CAUSE_USER_BUSY);
} else if (!strcmp(app, "ring")) {
originate_global_t *oglobals = (originate_global_t *) switch_channel_get_private(channel, "_oglobals_");
const char *bd = switch_channel_get_variable(channel, "monitor_ring_dispo");
if (!bd) {
bd = "monitor_early_media_ring";
}
switch_channel_set_variable(channel, "originate_disposition", bd);
if (oglobals) {
switch_channel_set_private(channel, "_oglobals_", NULL);
if (!oglobals->progress) {
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论