[svn-commits] kmoore: branch 12 r400395 - in /branches/12: ./ res/res_rtp_multicast.c

SVN commits to the Digium repositories svn-commits at lists.digium.com
Thu Oct 3 13:29:00 CDT 2013


Author: kmoore
Date: Thu Oct  3 13:28:57 2013
New Revision: 400395

URL: http://svnview.digium.com/svn/asterisk?view=rev&rev=400395
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
........

Merged revisions 400394 from http://svn.asterisk.org/svn/asterisk/branches/11

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

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

Modified: branches/12/res/res_rtp_multicast.c
URL: http://svnview.digium.com/svn/asterisk/branches/12/res/res_rtp_multicast.c?view=diff&rev=400395&r1=400394&r2=400395
==============================================================================
--- branches/12/res/res_rtp_multicast.c (original)
+++ branches/12/res/res_rtp_multicast.c Thu Oct  3 13:28:57 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 svn-commits mailing list