diff mbox series

[FFmpeg-devel] avformat/mov.c: trun atom sample should be logged from 0

Message ID 20210605135446.5529-1-val.zapod.vz@gmail.com
State New
Headers show
Series [FFmpeg-devel] avformat/mov.c: trun atom sample should be logged from 0 | expand


Context Check Description
andriy/x86_make success Make finished
andriy/x86_make_fate success Make fate finished
andriy/PPC64_make success Make finished
andriy/PPC64_make_fate success Make fate finished

Commit Message

Valerii Zapodovnikov June 5, 2021, 1:54 p.m. UTC
Just like for stss atom.

Suggested-By: Nick Ryan <nick.paul.ryan@gmail.com>
 libavformat/mov.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
diff mbox series


diff --git a/libavformat/mov.c b/libavformat/mov.c
index c088c9f515..1be2783556 100644
--- a/libavformat/mov.c
+++ b/libavformat/mov.c
@@ -4936,11 +4936,11 @@  static int mov_read_trun(MOVContext *c, AVIOContext *pb, MOVAtom atom)
         sc->ctts_data[index_entry_pos].count = 1;
         sc->ctts_data[index_entry_pos].duration = ctts_duration;
-        index_entry_pos++;
         av_log(c->fc, AV_LOG_TRACE, "AVIndex stream %d, sample %d, offset %"PRIx64", dts %"PRId64", "
                 "size %u, distance %d, keyframe %d\n", st->index,
                 index_entry_pos, offset, dts, sample_size, distance, keyframe);
+        index_entry_pos++;
         dts += sample_duration;
         offset += sample_size;