提交 44749cd1 authored 作者: Anthony Minessale's avatar Anthony Minessale

set flag to avoid race on transfer -both

git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@9257 d0543943-73ff-0310-b7d9-9358b9ac24b2
上级 7e38be6d
...@@ -881,6 +881,9 @@ SWITCH_STANDARD_API(transfer_function) ...@@ -881,6 +881,9 @@ SWITCH_STANDARD_API(transfer_function)
} }
} else if (!strcasecmp(arg, "both")) { } else if (!strcasecmp(arg, "both")) {
if (uuid && (other_session = switch_core_session_locate(uuid))) { if (uuid && (other_session = switch_core_session_locate(uuid))) {
switch_channel_t *other_channel = switch_core_session_get_channel(other_session);
switch_channel_set_flag(other_channel, CF_TRANSFER);
switch_channel_set_flag(channel, CF_TRANSFER);
switch_ivr_session_transfer(other_session, dest, dp, context); switch_ivr_session_transfer(other_session, dest, dp, context);
switch_core_session_rwunlock(other_session); switch_core_session_rwunlock(other_session);
} }
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论