[asterisk-commits] kmoore: branch 11 r400394 - in /branches/11: ./ res/res_rtp_multicast.c

SVN commits to the Asterisk project asterisk-commits at lists.digium.com
Thu Oct 3 13:28:09 CDT 2013


Author: kmoore
Date: Thu Oct  3 13:28:07 2013
New Revision: 400394

URL: http://svnview.digium.com/svn/asterisk?view=rev&rev=400394
Log:
Ensure res_rtp_mutlicast sets SSRC properly

This fixes a bug where the SSRC field on multicast RTP can be stuck at
0 which can cause problems for endpoints trying to make sense of
incoming streams.

(closes issue ASTERISK-22567)
Reported by: Simone Camporeale
Patches:
    22567_res_mulitcast_ssrc.patch uploaded by Simone Camporeale (License 6536)
........

Merged revisions 400393 from http://svn.asterisk.org/svn/asterisk/branches/1.8

Modified:
    branches/11/   (props changed)
    branches/11/res/res_rtp_multicast.c

Propchange: branches/11/
------------------------------------------------------------------------------
Binary property 'branch-1.8-merged' - no diff available.

Modified: branches/11/res/res_rtp_multicast.c
URL: http://svnview.digium.com/svn/asterisk/branches/11/res/res_rtp_multicast.c?view=diff&rev=400394&r1=400393&r2=400394
==============================================================================
--- branches/11/res/res_rtp_multicast.c (original)
+++ branches/11/res/res_rtp_multicast.c Thu Oct  3 13:28:07 2013
@@ -260,14 +260,14 @@
 	/* Construct an RTP header for our packet */
 	rtpheader = (unsigned char *)(f->data.ptr - hdrlen);
 	put_unaligned_uint32(rtpheader, htonl((2 << 30) | (codec << 16) | (multicast->seqno)));
-	put_unaligned_uint32(rtpheader + 4, htonl(multicast->lastts));
 	
 	if (ast_test_flag(f, AST_FRFLAG_HAS_TIMING_INFO)) {
 		put_unaligned_uint32(rtpheader + 4, htonl(f->ts * 8));
-	} 
-	else {
-		put_unaligned_uint32(rtpheader + 8, htonl(multicast->ssrc));
-	}
+	} else {
+		put_unaligned_uint32(rtpheader + 4, htonl(multicast->lastts));
+	}
+
+	put_unaligned_uint32(rtpheader + 8, htonl(multicast->ssrc));
 
 	/* Increment sequence number and wrap to 0 if it overflows 16 bits. */
 	multicast->seqno = 0xFFFF & (multicast->seqno + 1);




More information about the asterisk-commits mailing list