提交 46f6c6e4 authored 作者: Anthony Minessale's avatar Anthony Minessale

fix regression from f60fdf65

上级 b6ac0012
......@@ -2774,7 +2774,7 @@ static switch_call_cause_t group_outgoing_channel(switch_core_session_t *session
switch_originate_flag_t myflags = SOF_NONE;
char *cid_name_override = NULL;
char *cid_num_override = NULL;
char *domain = NULL;
char *domain = NULL, *dup_domain = NULL;
switch_channel_t *new_channel = NULL;
unsigned int timelimit = 60;
const char *skip, *var;
......@@ -2788,6 +2788,7 @@ static switch_call_cause_t group_outgoing_channel(switch_core_session_t *session
*domain++ = '\0';
} else {
domain = switch_core_get_variable_pdup("domain", switch_core_session_get_pool(session));
dup_domain = domain;
}
if (!domain) {
......@@ -2859,6 +2860,7 @@ static switch_call_cause_t group_outgoing_channel(switch_core_session_t *session
switch_safe_free(template);
switch_safe_free(group);
switch_safe_free(dup_domain);
if (cause == SWITCH_CAUSE_NONE) {
cause = SWITCH_CAUSE_DESTINATION_OUT_OF_ORDER;
......
......@@ -309,11 +309,13 @@ static switch_call_cause_t sip_outgoing_channel(switch_core_session_t *session,
switch_call_cause_t *cancel_cause)
{
const char *profile;
char *dup_profile = NULL;
if (session) {
profile = switch_channel_get_variable(switch_core_session_get_channel(session), "sip_profile");
} else {
profile = switch_core_get_variable_pdup("sip_profile", switch_core_session_get_pool(session));
dup_profile = switch_core_get_variable_dup("sip_profile");
profile = dup_profile;
}
if (zstr(profile)) {
profile = "default";
......@@ -323,6 +325,8 @@ static switch_call_cause_t sip_outgoing_channel(switch_core_session_t *session,
UNPROTECT_INTERFACE(sip_endpoint_interface);
switch_safe_free(dup_profile);
return switch_core_session_outgoing_channel(session, var_event, "sofia", outbound_profile, new_session, pool, SOF_NONE, cancel_cause);
}
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论