[Asterisk-cvs] asterisk rtp.c,1.47.2.1,1.47.2.2

markster at lists.digium.com markster at lists.digium.com
Sun Mar 14 17:56:29 CST 2004


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

Modified Files:
      Tag: v1-0_stable
	rtp.c 
Log Message:
Ignore audio from RTP peers who have not given us their address yet (Plexus workaround)


Index: rtp.c
===================================================================
RCS file: /usr/cvsroot/asterisk/rtp.c,v
retrieving revision 1.47.2.1
retrieving revision 1.47.2.2
diff -u -d -r1.47.2.1 -r1.47.2.2
--- rtp.c	18 Feb 2004 21:38:18 -0000	1.47.2.1
+++ rtp.c	14 Mar 2004 22:50:27 -0000	1.47.2.2
@@ -389,6 +389,11 @@
 			ast_log(LOG_DEBUG, "RTP NAT: Using address %s:%d\n", inet_ntoa(rtp->them.sin_addr), ntohs(rtp->them.sin_port));
 		}
 	}
+	/* Ignore if the other side hasn't been given an address
+	   yet.  */
+	if (!rtp->them.sin_addr.s_addr || !rtp->them.sin_port)
+		return &null_frame;
+
 	/* Get fields */
 	seqno = ntohl(rtpheader[0]);
 	payloadtype = (seqno & 0x7f0000) >> 16;




More information about the svn-commits mailing list