[Freeswitch-svn] [commit] r11636 - freeswitch/trunk/src/mod/endpoints/mod_sofia

FreeSWITCH SVN anthm at freeswitch.org
Wed Feb 4 12:25:46 PST 2009


Author: anthm
Date: Wed Feb  4 14:25:46 2009
New Revision: 11636

Log:
tolerate missing user in the request uri

Modified:
   freeswitch/trunk/src/mod/endpoints/mod_sofia/sofia.c

Modified: freeswitch/trunk/src/mod/endpoints/mod_sofia/sofia.c
==============================================================================
--- freeswitch/trunk/src/mod/endpoints/mod_sofia/sofia.c	(original)
+++ freeswitch/trunk/src/mod/endpoints/mod_sofia/sofia.c	Wed Feb  4 14:25:46 2009
@@ -4113,10 +4113,18 @@
 		} else {
 			destination_number = sip->sip_request->rq_url->url_user;
 		}
-		check_decode(destination_number, session);
 	}
 
-
+	if (!destination_number && sip->sip_to && sip->sip_to->a_url) {
+		destination_number = sip->sip_to->a_url->url_user;
+	}
+	
+	if (destination_number) {
+		check_decode(destination_number, session);
+	} else {
+		destination_number = "service";
+	}
+	
 	if (sip->sip_to && sip->sip_to->a_url) {
 		const char *host, *user;
 		int port;



More information about the Freeswitch-svn mailing list