mirror of
https://github.com/signalwire/freeswitch.git
synced 2026-11-08 12:34:53 +00:00
patch for SFSIP-104
git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@10544 d0543943-73ff-0310-b7d9-9358b9ac24b2
This commit is contained in:
1 parent
085771a4cc
commit
958671cfbe
3 files changed
+18
-4
No files matched your search
@@ -1540,7 +1540,8 @@ void sofia_presence_handle_sip_i_subscribe(int status,
|
||||
|
||||
if (status < 200) {
|
||||
char *sticky = NULL;
|
||||
|
||||
char *contact_str = profile->url;
|
||||
|
||||
if (is_nat) {
|
||||
char params[128] = "";
|
||||
if (contact->m_url->url_params) {
|
||||
@@ -1555,9 +1556,16 @@ void sofia_presence_handle_sip_i_subscribe(int status,
|
||||
network_port,
|
||||
params);
|
||||
}
|
||||
|
||||
if (switch_stristr("port=tcp", contact->m_url->url_params)) {
|
||||
contact_str = profile->tcp_contact;
|
||||
} else if (switch_stristr("port=tls", contact->m_url->url_params)) {
|
||||
contact_str = profile->tls_contact;
|
||||
}
|
||||
|
||||
nua_respond(nh, SIP_202_ACCEPTED, NUTAG_WITH_THIS(nua), SIPTAG_SUBSCRIPTION_STATE_STR(sstr), TAG_IF(sticky, NUTAG_PROXY(sticky)),
|
||||
TAG_END());
|
||||
|
||||
nua_respond(nh, SIP_202_ACCEPTED, SIPTAG_CONTACT_STR(contact_str), NUTAG_WITH_THIS(nua), SIPTAG_SUBSCRIPTION_STATE_STR(sstr),
|
||||
TAG_IF(sticky, NUTAG_PROXY(sticky)), TAG_END());
|
||||
|
||||
switch_safe_free(sticky);
|
||||
|
||||
|
||||
Reference in new issue
Block a user