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

Modify Originate input syntax

This adds the | to the originate syntax 
making it possible to put a list of urls to call and attempt
to call them one at a time until one of them is successful or there
are none of them left

The original & delimited list is valid for each step in the | separated
list

Example
sofia/test-int/3920@10.3.3.104|sofia/test-int/3910@10.3.3.104&sofia/test-int/3920@10.3.3.104

first call 1 location and if that results in a failure, try 2 at once on the next go



git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@2996 d0543943-73ff-0310-b7d9-9358b9ac24b2
上级 b9a350a4
......@@ -151,7 +151,7 @@ switch_mutex_unlock(obj->flag_mutex);
/*!
\brief Free a pointer and set it to NULL unles it already is NULL
\brief Free a pointer and set it to NULL unless it already is NULL
\param it the pointer
*/
#define switch_safe_free(it) if (it) {free(it);it=NULL;}
......
......@@ -1676,7 +1676,6 @@ static switch_status_t sofia_outgoing_channel(switch_core_session_t *session, sw
sofia_profile_t *profile;
switch_caller_profile_t *caller_profile = NULL;
private_object_t *tech_pvt = NULL;
switch_channel_t *channel;
switch_channel_t *nchannel;
char *host;
......@@ -1725,7 +1724,7 @@ static switch_status_t sofia_outgoing_channel(switch_core_session_t *session, sw
snprintf(tech_pvt->dest, strlen(dest) + 5, "sip:%s", dest);
}
attach_private(nsession, profile, tech_pvt, dest);
channel = switch_core_session_get_channel(session);
nchannel = switch_core_session_get_channel(nsession);
caller_profile = switch_caller_profile_clone(nsession, outbound_profile);
switch_channel_set_caller_profile(nchannel, caller_profile);
......@@ -1737,6 +1736,7 @@ static switch_status_t sofia_outgoing_channel(switch_core_session_t *session, sw
status = SWITCH_STATUS_SUCCESS;
if (session) {
char *val;
switch_channel_t *channel = switch_core_session_get_channel(session);
switch_ivr_transfer_variable(session, nsession, SOFIA_REPLACES_HEADER);
if (switch_channel_test_flag(channel, CF_NOMEDIA) && (val = switch_channel_get_variable(channel, SWITCH_R_SDP_VARIABLE))) {
......
差异被折叠。
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论