]> git.ipfire.org Git - thirdparty/asterisk.git/commit
res_rtp_asterisk: Correct erroneous lost packet information in RTCP reports
authorMatthew Jordan <mjordan@digium.com>
Sat, 28 Sep 2013 22:41:36 +0000 (22:41 +0000)
committerMatthew Jordan <mjordan@digium.com>
Sat, 28 Sep 2013 22:41:36 +0000 (22:41 +0000)
commitbca6c2fb4b1618d4f2ef771f260e2965715e1ab4
treec0f24a671db779732474ab6e59ed7ad9bbb4ebc9
parent45d756058824e89dd6b6534cef4cbc7efa35f64a
res_rtp_asterisk: Correct erroneous lost packet information in RTCP reports

RTCP's calculation of the number of lost packets in an RTP stream is based on
that stream's sequence number count, the number of received packets, and how
many packets we expect to receive. When the SSRC for an RTP stream changes,
there can - and almost always will be - a large jump in the next packet's
timestamp and sequence number. If we don't reset the number of received
packets, sequence number count, and other metrics used by RTCP, the next RR/SR
report will use the previous SSRC's values to calculate the lost packet count
for the new SSRC - resulting in a very large number of lost packets.

This patch modifies res_rtp_asterisk such that, if it detects a SSRC change, it
will reset the various values used by the RTCP calculations. From the
perspective of RTCP, this appears as a new media stream - which is what it is.

Review: https://reviewboard.asterisk.org/r/2886/

(closes issue AST-1174)
Reported by: Thomas Arimont
........

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

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

git-svn-id: https://origsvn.digium.com/svn/asterisk/certified/branches/11.2@400119 65c4cc65-6c06-0410-ace0-fbb531ad65f3
res/res_rtp_asterisk.c