[Asterisk-cvs] asterisk/channels chan_sip.c,1.393,1.394

markster at lists.digium.com markster at lists.digium.com
Thu May 20 20:46:47 CDT 2004


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

Modified Files:
	chan_sip.c 
Log Message:
Don't send the same codec twice even if listed twice in allow section (bug #1691)


Index: chan_sip.c
===================================================================
RCS file: /usr/cvsroot/asterisk/channels/chan_sip.c,v
retrieving revision 1.393
retrieving revision 1.394
diff -u -d -r1.393 -r1.394
--- chan_sip.c	20 May 2004 07:52:07 -0000	1.393
+++ chan_sip.c	21 May 2004 00:59:38 -0000	1.394
@@ -3088,7 +3088,7 @@
 	/* Start by sending our preferred codecs */
 	cur = prefs;
 	while(cur) {
-		if (p->jointcapability & cur->codec) {
+		if ((p->jointcapability & cur->codec) && !(alreadysent & cur->codec)) {
 			if (sip_debug_test_pvt(p))
 				ast_verbose("Answering with preferred capability 0x%x(%s)\n", cur->codec, ast_getformatname(cur->codec));
 			codec = ast_rtp_lookup_code(p->rtp, 1, cur->codec);




More information about the svn-commits mailing list