[FFmpeg-cvslog] rtpdec: Handle more received packets than expected when sending RR

Martin Storsjö git at videolan.org
Tue Jan 15 14:46:28 CET 2013


ffmpeg | branch: master | Martin Storsjö <martin at martin.st> | Mon Jan 14 11:34:19 2013 +0200| [30b50f79aea355f3cf1b08dbfc36754689fd6383] | committer: Martin Storsjö

rtpdec: Handle more received packets than expected when sending RR

Without this, we'd signal a huge loss rate (due to unsigned
wraparound) if we had received one packet more than expected (that
is, one seq number sent twice). The code has a check for lost_interval
<= 0, but that doesn't do what was intended as long as the variable is
unsigned.

Signed-off-by: Martin Storsjö <martin at martin.st>

> http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=30b50f79aea355f3cf1b08dbfc36754689fd6383
---

 libavformat/rtpdec.c |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/libavformat/rtpdec.c b/libavformat/rtpdec.c
index 1ccc0f6..73d0206 100644
--- a/libavformat/rtpdec.c
+++ b/libavformat/rtpdec.c
@@ -258,7 +258,7 @@ int ff_rtp_check_and_send_back_rr(RTPDemuxContext *s, URLContext *fd,
     uint32_t extended_max;
     uint32_t expected_interval;
     uint32_t received_interval;
-    uint32_t lost_interval;
+    int32_t  lost_interval;
     uint32_t expected;
     uint32_t fraction;
 



More information about the ffmpeg-cvslog mailing list