mirror of
https://github.com/signalwire/freeswitch.git
synced 2025-03-30 10:15:52 +00:00
use register contact to determine proper contact in 200 ok response to register
This commit is contained in:
parent
868d8230d1
commit
f9612fecfe
@ -1831,8 +1831,17 @@ void sofia_reg_handle_sip_r_register(int status,
|
||||
const char *new_expires;
|
||||
uint32_t expi;
|
||||
if (contact->m_next) {
|
||||
const char *sipip = profile->extsipip ? profile->extsipip : profile->sipip;
|
||||
for (; contact && strcasecmp(contact->m_url->url_host, sipip); contact = contact->m_next);
|
||||
char *full;
|
||||
|
||||
for (; contact; contact = contact->m_next) {
|
||||
if ((full = sip_header_as_string(nh->nh_home, (void *) contact))) {
|
||||
if (switch_stristr(sofia_private->gateway->register_contact, full)) {
|
||||
break;
|
||||
}
|
||||
|
||||
su_free(nh->nh_home, full);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
if (!contact) {
|
||||
|
Loading…
x
Reference in New Issue
Block a user