diff options
author | Luca Barbato <lu_zero@gentoo.org> | 2013-08-19 17:18:22 +0200 |
---|---|---|
committer | Luca Barbato <lu_zero@gentoo.org> | 2013-08-20 00:22:58 +0200 |
commit | 22de0f8369f1f3edf1a55e1d275f3c07c617b53e (patch) | |
tree | 1852cc437160b8b2eb444d39b80c018a351c94f9 /libavformat | |
parent | 39523030108815242178ac5e209c83070bd1baef (diff) | |
download | ffmpeg-22de0f8369f1f3edf1a55e1d275f3c07c617b53e.tar.gz |
mov: Compute max duration among the tracks with a timescale
Prevent an assert.
Diffstat (limited to 'libavformat')
-rw-r--r-- | libavformat/movenc.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/libavformat/movenc.c b/libavformat/movenc.c index b41261c9a3..0f21ae2747 100644 --- a/libavformat/movenc.c +++ b/libavformat/movenc.c @@ -1640,7 +1640,7 @@ static int mov_write_mvhd_tag(AVIOContext *pb, MOVMuxContext *mov) int version; for (i = 0; i < mov->nb_streams; i++) { - if (mov->tracks[i].entry > 0) { + if (mov->tracks[i].entry > 0 && mov->tracks[i].timescale) { max_track_len_temp = av_rescale_rnd(mov->tracks[i].track_duration, MOV_TIMESCALE, mov->tracks[i].timescale, |