]> git.ipfire.org Git - thirdparty/freeswitch.git/commitdiff
MODENDP-291
authorBrian West <brian@freeswitch.org>
Wed, 27 Jan 2010 15:36:24 +0000 (15:36 +0000)
committerBrian West <brian@freeswitch.org>
Wed, 27 Jan 2010 15:36:24 +0000 (15:36 +0000)
git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@16524 d0543943-73ff-0310-b7d9-9358b9ac24b2

src/mod/endpoints/mod_sofia/sofia.c

index 0a8102bcc6c8e94f35e0d047d15df5f8886a4f95..8a4ab4d29667d21442c851a989115262fd190fc6 100644 (file)
@@ -5095,10 +5095,6 @@ void sofia_handle_sip_i_refer(nua_t *nua, sofia_profile_t *profile, nua_handle_t
                                                                port = refer_to->r_url->url_port;
                                                        }
 
-                                                       if (zstr(port)) {
-                                                               port = "5060";
-                                                       }
-                                                       
                                                        channel = switch_core_session_get_channel(a_session);
                                                        
                                                        if (refer_to->r_params) {
@@ -5121,9 +5117,10 @@ void sofia_handle_sip_i_refer(nua_t *nua, sofia_profile_t *profile, nua_handle_t
                                                                }
                                                        }
 
-                                                       exten = switch_core_session_sprintf(session, "sofia/%s/sip:%s@%s", 
+                                                       exten = switch_core_session_sprintf(session, "sofia/%s/sip:%s@%s%s%s", 
                                                                                                                                profile->name, refer_to->r_url->url_user, 
-                                                                                                                               refer_to->r_url->url_host);
+                                                                                                                               refer_to->r_url->url_host,
+                                                                                                                               port ? ":" : "", port ? port : "");
 
                                                        switch_core_new_memory_pool(&npool);
                                                        nightmare_xfer_helper = switch_core_alloc(npool, sizeof(*nightmare_xfer_helper));