[Asterisk-cvs] asterisk/channels chan_sip.c,1.872,1.873

kpfleming kpfleming
Tue Oct 4 18:13:36 CDT 2005


Update of /usr/cvsroot/asterisk/channels
In directory mongoose.digium.com:/tmp/cvs-serv1192/channels

Modified Files:
	chan_sip.c 
Log Message:
don't destroy calls when re-INVITE messages ask for things we can't do (issue #5384)


Index: chan_sip.c
===================================================================
RCS file: /usr/cvsroot/asterisk/channels/chan_sip.c,v
retrieving revision 1.872
retrieving revision 1.873
diff -u -d -r1.872 -r1.873
--- chan_sip.c	29 Sep 2005 17:41:00 -0000	1.872
+++ chan_sip.c	4 Oct 2005 22:09:23 -0000	1.873
@@ -10103,7 +10103,8 @@
 		if (required_profile) { 	/* They require something */
 			/* At this point we support no extensions, so fail */
 			transmit_response_with_unsupported(p, "420 Bad extension", req, required);
-			ast_set_flag(p, SIP_NEEDDESTROY);	
+			if (!p->lastinvite)
+				ast_set_flag(p, SIP_NEEDDESTROY);	
 			return -1;
 			
 		}
@@ -10136,7 +10137,8 @@
 			if (!strcasecmp(get_header(req, "Content-Type"), "application/sdp")) {
 				if (process_sdp(p, req)) {
 					transmit_response(p, "488 Not acceptable here", req);
-					ast_set_flag(p, SIP_NEEDDESTROY);	
+					if (!p->lastinvite)
+						ast_set_flag(p, SIP_NEEDDESTROY);	
 					return -1;
 				}
 			} else {




More information about the svn-commits mailing list