diff --git a/libavformat/wtvdec.c b/libavformat/wtvdec.c index 77908e6392..6c41e3c1a3 100644 --- a/libavformat/wtvdec.c +++ b/libavformat/wtvdec.c @@ -953,6 +953,9 @@ static int parse_chunks(AVFormatContext *s, int mode, int64_t seekts, int *len_p } else av_log(s, AV_LOG_WARNING, "unsupported chunk:"FF_PRI_GUID"\n", FF_ARG_GUID(g)); + if (avio_feof(pb)) + break; + avio_skip(pb, WTV_PAD8(len) - consumed); } return AVERROR_EOF;