[FFmpeg-devel] [PATCH 1/6] avformat/rtpdec: update the previous with new seq

lance.lmwang at gmail.com lance.lmwang at gmail.com
Wed Oct 14 17:34:58 EEST 2020


From: Limin Wang <lance.lmwang at gmail.com>

If the rtp input is discontinued, we'll drop all the new received packets now,
It's better to update the previous seq with the new seq so that the following
packets will not be dropped always.

Signed-off-by: Limin Wang <lance.lmwang at gmail.com>
---
 libavformat/rtpdec.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/libavformat/rtpdec.c b/libavformat/rtpdec.c
index 3d5b200..de79536 100644
--- a/libavformat/rtpdec.c
+++ b/libavformat/rtpdec.c
@@ -833,6 +833,7 @@ static int rtp_parse_one_packet(RTPDemuxContext *s, AVPacket *pkt,
             /* Packet older than the previously emitted one, drop */
             av_log(s->ic, AV_LOG_WARNING,
                    "RTP: dropping old packet received too late\n");
+            s->seq = seq;
             return -1;
         } else if (diff <= 1) {
             /* Correct packet */
-- 
1.8.3.1



More information about the ffmpeg-devel mailing list