From: Anthony Minessale Date: Fri, 13 Apr 2012 16:37:06 +0000 (-0500) Subject: FS-4110 --resolve yes this block is wrong we can't guess the right presence id here X-Git-Tag: v1.2-rc1~17^2~227 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=0eb9b0101fbca6f77c0bfe622486a363c359e489;p=thirdparty%2Ffreeswitch.git FS-4110 --resolve yes this block is wrong we can't guess the right presence id here --- diff --git a/src/mod/endpoints/mod_sofia/sofia_glue.c b/src/mod/endpoints/mod_sofia/sofia_glue.c index 80dfff8835..b1995580a3 100644 --- a/src/mod/endpoints/mod_sofia/sofia_glue.c +++ b/src/mod/endpoints/mod_sofia/sofia_glue.c @@ -2355,28 +2355,6 @@ switch_status_t sofia_glue_do_invite(switch_core_session_t *session) switch_channel_set_variable(channel, "sip_to_host", sofia_glue_get_host(to_str, switch_core_session_get_pool(session))); switch_channel_set_variable(channel, "sip_from_host", sofia_glue_get_host(from_str, switch_core_session_get_pool(session))); - if (!switch_channel_get_variable(channel, "presence_id")) { - char *from = switch_core_session_strdup(session, from_str); - const char *s; - - if ((s = switch_stristr("<", from))) { - from = (char *)s + 1; - } - - if (!strncasecmp(from, "sip:", 4)) { - from += 4; - } - - if (!strncasecmp(from, "sips:", 5)) { - from += 5; - } - - if ((p = strchr(from, ':')) || (p = strchr(from, ';')) || (p = strchr(from, '>'))) { - *p++ = '\0'; - } - - switch_channel_set_variable(channel, "presence_id", from); - } if (!(tech_pvt->nh = nua_handle(tech_pvt->profile->nua, NULL, NUTAG_URL(url_str),