mirror of https://git.ffmpeg.org/ffmpeg.git
avformat/cafdec: try skipping various chunks only when seeking is possible
This commit is contained in:
parent
646afae00f
commit
11d39873ab
|
@ -328,7 +328,7 @@ static int read_header(AVFormatContext *s)
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (size > 0) {
|
if (size > 0 && (pb->seekable & AVIO_SEEKABLE_NORMAL)) {
|
||||||
if (pos > INT64_MAX - size)
|
if (pos > INT64_MAX - size)
|
||||||
return AVERROR_INVALIDDATA;
|
return AVERROR_INVALIDDATA;
|
||||||
avio_skip(pb, FFMAX(0, pos + size - avio_tell(pb)));
|
avio_skip(pb, FFMAX(0, pos + size - avio_tell(pb)));
|
||||||
|
|
Loading…
Reference in New Issue