From 4d20dd3e9a1ce93dda2ebd51123832417524d15f Mon Sep 17 00:00:00 2001 From: Anthony Minessale Date: Thu, 3 Jul 2008 16:48:05 +0000 Subject: [PATCH] fix git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@8888 d0543943-73ff-0310-b7d9-9358b9ac24b2 --- src/mod/endpoints/mod_sofia/sofia_glue.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/mod/endpoints/mod_sofia/sofia_glue.c b/src/mod/endpoints/mod_sofia/sofia_glue.c index 89065e73f9..85f4ba2d02 100644 --- a/src/mod/endpoints/mod_sofia/sofia_glue.c +++ b/src/mod/endpoints/mod_sofia/sofia_glue.c @@ -1073,8 +1073,8 @@ switch_status_t sofia_glue_do_invite(switch_core_session_t *session) TAG_END()); - if (strstr(tech_pvt->dest, ";fs_nat") || strstr(tech_pvt->dest, ";received") - || ((val = switch_channel_get_variable(channel, "sip_sticky_contact")) && switch_true(val))) { + if (tech_pvt->dest && (strstr(tech_pvt->dest, ";fs_nat") || strstr(tech_pvt->dest, ";received") + || ((val = switch_channel_get_variable(channel, "sip_sticky_contact")) && switch_true(val)))) { switch_set_flag(tech_pvt, TFLAG_NAT); tech_pvt->record_route = switch_core_session_strdup(tech_pvt->session, url_str); route_uri = tech_pvt->record_route; @@ -1172,7 +1172,7 @@ switch_status_t sofia_glue_do_invite(switch_core_session_t *session) call_id = switch_channel_get_variable(channel, "sip_outgoing_call_id"); - if ((route = strstr(tech_pvt->dest, ";fs_path="))) { + if (tech_pvt->dest && (route = strstr(tech_pvt->dest, ";fs_path="))) { char *p; route = switch_core_session_strdup(tech_pvt->session, route + 9);