diff options
author | vectronic <hello.vectronic@gmail.com> | 2019-09-16 11:44:28 +0100 |
---|---|---|
committer | Steven Liu <lq@chinaffmpeg.org> | 2019-09-23 10:06:46 +0800 |
commit | 8c90bb8ebb6e60d1e6f48259091c0f3f7ff57b3e (patch) | |
tree | 54511aa60671e9d71ec5ccaa573721d57febb43c | |
parent | 598962cd3a68e30662cfbd5e053eef85d2ee3a8a (diff) | |
download | ffmpeg-8c90bb8ebb6e60d1e6f48259091c0f3f7ff57b3e.tar.gz |
avformat/dashdec: fix segfault when parsing segmentlist
index into segmentlists_tab was specified as 4 instead of 3 causing invalid access
further fix to: 8135
Reviewed-by: Steven Liu <lq@onvideo.cn>
Signed-off-by: vectronic <hello.vectronic@gmail.com>
-rw-r--r-- | libavformat/dashdec.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/libavformat/dashdec.c b/libavformat/dashdec.c index 738bfeaefb..7713ee8907 100644 --- a/libavformat/dashdec.c +++ b/libavformat/dashdec.c @@ -1017,7 +1017,7 @@ static int parse_manifest_representation(AVFormatContext *s, const char *url, duration_val = get_val_from_nodes_tab(segmentlists_tab, 3, "duration"); timescale_val = get_val_from_nodes_tab(segmentlists_tab, 3, "timescale"); - startnumber_val = get_val_from_nodes_tab(segmentlists_tab, 4, "startNumber"); + startnumber_val = get_val_from_nodes_tab(segmentlists_tab, 3, "startNumber"); if (duration_val) { rep->fragment_duration = (int64_t) strtoll(duration_val, NULL, 10); av_log(s, AV_LOG_TRACE, "rep->fragment_duration = [%"PRId64"]\n", rep->fragment_duration); |