diff options
author | Carl Eugen Hoyos <ceffmpeg@gmail.com> | 2018-02-11 20:41:32 +0100 |
---|---|---|
committer | Carl Eugen Hoyos <ceffmpeg@gmail.com> | 2018-02-12 22:50:52 +0100 |
commit | d401ba6b3d86091dff2fae326c610f0120ee8853 (patch) | |
tree | 1f43e4c09babe4d80408973e94bf3347a1de80aa | |
parent | 81d1e1e5094bfb85464f87f51f22b0b5ca4d84bb (diff) | |
download | ffmpeg-d401ba6b3d86091dff2fae326c610f0120ee8853.tar.gz |
lavf/matroskaenc: Force the minimum value for -reserve_index_space to 2.
Fixes an assertion failure:
Assertion size >= 2 failed at libavformat/matroskaenc.c:298
-rw-r--r-- | libavformat/matroskaenc.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/libavformat/matroskaenc.c b/libavformat/matroskaenc.c index f22c2ab70c..5950b4de44 100644 --- a/libavformat/matroskaenc.c +++ b/libavformat/matroskaenc.c @@ -2001,6 +2001,8 @@ static int mkv_write_header(AVFormatContext *s) } if ((pb->seekable & AVIO_SEEKABLE_NORMAL) && mkv->reserve_cues_space) { mkv->cues_pos = avio_tell(pb); + if (mkv->reserve_cues_space == 1) + mkv->reserve_cues_space++; put_ebml_void(pb, mkv->reserve_cues_space); } |