提交 2423fc7d authored 作者: Anthony Minessale's avatar Anthony Minessale

FS-6540 This should proxy all refers now, the param has changed to proxy-refer

上级 7f9348db
...@@ -277,7 +277,7 @@ typedef enum { ...@@ -277,7 +277,7 @@ typedef enum {
PFLAG_TCP_ALWAYS_NAT, PFLAG_TCP_ALWAYS_NAT,
PFLAG_ENABLE_CHAT, PFLAG_ENABLE_CHAT,
PFLAG_AUTH_SUBSCRIPTIONS, PFLAG_AUTH_SUBSCRIPTIONS,
PFLAG_PROXY_REFER_REPLACES, PFLAG_PROXY_REFER,
/* No new flags below this line */ /* No new flags below this line */
PFLAG_MAX PFLAG_MAX
} PFLAGS; } PFLAGS;
......
...@@ -4101,11 +4101,11 @@ switch_status_t config_sofia(sofia_config_t reload, char *profile_name) ...@@ -4101,11 +4101,11 @@ switch_status_t config_sofia(sofia_config_t reload, char *profile_name)
} else if (!strcasecmp(var, "tcp-ping2pong") && !zstr(val)) { } else if (!strcasecmp(var, "tcp-ping2pong") && !zstr(val)) {
profile->tcp_ping2pong = atoi(val); profile->tcp_ping2pong = atoi(val);
sofia_set_pflag(profile, PFLAG_TCP_PING2PONG); sofia_set_pflag(profile, PFLAG_TCP_PING2PONG);
} else if (!strcasecmp(var, "proxy-refer-replaces") && !zstr(val)) { } else if ((!strcasecmp(var, "proxy-refer-replaces") || !strcasecmp(var, "proxy-refer")) && !zstr(val)) {
if (switch_true(val)) { if (switch_true(val)) {
sofia_set_pflag(profile, PFLAG_PROXY_REFER_REPLACES); sofia_set_pflag(profile, PFLAG_PROXY_REFER);
} else { } else {
sofia_clear_pflag(profile, PFLAG_PROXY_REFER_REPLACES); sofia_clear_pflag(profile, PFLAG_PROXY_REFER);
} }
} else if (!strcasecmp(var, "sip-messages-respond-200-ok") && !zstr(val)) { } else if (!strcasecmp(var, "sip-messages-respond-200-ok") && !zstr(val)) {
if (switch_true(val)) { if (switch_true(val)) {
...@@ -7450,10 +7450,10 @@ void sofia_handle_sip_i_refer(nua_t *nua, sofia_profile_t *profile, nua_handle_t ...@@ -7450,10 +7450,10 @@ void sofia_handle_sip_i_refer(nua_t *nua, sofia_profile_t *profile, nua_handle_t
} }
if (sofia_test_pflag(profile, PFLAG_PROXY_REFER_REPLACES)) { if (sofia_test_pflag(profile, PFLAG_PROXY_REFER)) {
switch_core_session_t *other_session; switch_core_session_t *other_session;
if (switch_stristr("replaces=", full_ref_to) && switch_core_session_get_partner(session, &other_session) == SWITCH_STATUS_SUCCESS) { if (switch_core_session_get_partner(session, &other_session) == SWITCH_STATUS_SUCCESS) {
switch_core_session_message_t *msg; switch_core_session_message_t *msg;
msg = switch_core_session_alloc(other_session, sizeof(*msg)); msg = switch_core_session_alloc(other_session, sizeof(*msg));
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论