avformat/mov.c: require tfhd to begin parsing trun
authorchcunningham <chcunningham@chromium.org>
Thu, 7 Feb 2019 00:12:51 +0000 (16:12 -0800)
committerMichael Niedermayer <michael@niedermayer.cc>
Fri, 8 Feb 2019 11:22:13 +0000 (12:22 +0100)
commitbcc71f30adc9de8b02f0b54636f02f20f71ef065
tree430a937cd71826452c4ab0105387b82499a925a4
parent31a1d2aa83096c3a07bd2f943bb9be6bda411147
avformat/mov.c: require tfhd to begin parsing trun

Detecting missing tfhd avoids re-using tfhd track info from the previous
moof. For files with multiple tracks, this may make a mess of the
avindex and fragindex, which can later trigger av_assert0 in
mov_read_trun().

Reviewed-by: Derek Buitenhuis <derek.buitenhuis@gmail.com>
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
(cherry picked from commit 3ea87e5d9ea075d5b3c0f4f8c6c48e514b454cbe)
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
libavformat/isom.h
libavformat/mov.c