diff mbox series

[FFmpeg-devel] fix typo in avformat/mov.c

Message ID 1590089578-4689-1-git-send-email-nicolas.dato@gmail.com
State New
Headers show
Series [FFmpeg-devel] fix typo in avformat/mov.c
Related show

Checks

Context Check Description
andriy/default pending
andriy/make success Make finished
andriy/make_fate fail Make fate failed

Commit Message

Nicolas Dato May 21, 2020, 7:32 p.m. UTC
avformat/mov: typo. when sidx time is found should assing it to pts instead of dts

    Fixes: AVPacket.dts was't monotonically increasing
---
 libavformat/mov.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
diff mbox series

Patch

diff --git a/libavformat/mov.c b/libavformat/mov.c
index e11c9f4..b2132e6 100644
--- a/libavformat/mov.c
+++ b/libavformat/mov.c
@@ -4827,7 +4827,7 @@  static int mov_read_trun(MOVContext *c, AVIOContext *pb, MOVAtom atom)
         } else if (frag_stream_info->sidx_pts != AV_NOPTS_VALUE) {
             // FIXME: sidx earliest_presentation_time is *PTS*, s.b.
             // pts = frag_stream_info->sidx_pts;
-            dts = frag_stream_info->sidx_pts - sc->time_offset;
+            pts = frag_stream_info->sidx_pts - sc->time_offset;
             av_log(c->fc, AV_LOG_DEBUG, "found sidx time %"PRId64
                     ", using it for pts\n", pts);
         } else if (frag_stream_info->tfdt_dts != AV_NOPTS_VALUE) {