ffmpeg | branch: release/4.2 | Andreas Rheinhardt <andreas.rheinha...@gmail.com> | Tue Oct 22 14:54:09 2019 +0200| [4b9f3c4323d29af0e55222265fc92680c6480aec] | committer: Andreas Rheinhardt
avformat/mpeg: Don't use unintialized value vobsub_read_packet() didn't check whether an array of AVPackets was valid and therefore used uninitialized values. Reviewed-by: Michael Niedermayer <mich...@niedermayer.cc> Signed-off-by: Andreas Rheinhardt <andreas.rheinha...@gmail.com> (cherry picked from commit a39536caee6607f481e9075bfb11937f46a47489) > http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=4b9f3c4323d29af0e55222265fc92680c6480aec --- libavformat/mpeg.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/libavformat/mpeg.c b/libavformat/mpeg.c index d10dd45d5b..ff85ad54ee 100644 --- a/libavformat/mpeg.c +++ b/libavformat/mpeg.c @@ -915,6 +915,10 @@ static int vobsub_read_packet(AVFormatContext *s, AVPacket *pkt) FFDemuxSubtitlesQueue *tmpq = &vobsub->q[i]; int64_t ts; av_assert0(tmpq->nb_subs); + + if (tmpq->current_sub_idx >= tmpq->nb_subs) + continue; + ts = tmpq->subs[tmpq->current_sub_idx].pts; if (ts < min_ts) { min_ts = ts; _______________________________________________ ffmpeg-cvslog mailing list ffmpeg-cvslog@ffmpeg.org https://ffmpeg.org/mailman/listinfo/ffmpeg-cvslog To unsubscribe, visit link above, or email ffmpeg-cvslog-requ...@ffmpeg.org with subject "unsubscribe".