mirror of https://git.ffmpeg.org/ffmpeg.git
matroskadec: empty blocks are in fact valid.
This commit is contained in:
parent
23a8b4ddfc
commit
d31fb1a9e7
|
@ -1679,11 +1679,12 @@ static int matroska_parse_block(MatroskaDemuxContext *matroska, uint8_t *data,
|
|||
size -= n;
|
||||
|
||||
track = matroska_find_track_by_num(matroska, num);
|
||||
if (size <= 3 || !track || !track->stream) {
|
||||
if (!track || !track->stream) {
|
||||
av_log(matroska->ctx, AV_LOG_INFO,
|
||||
"Invalid stream %"PRIu64" or size %u\n", num, size);
|
||||
return AVERROR_INVALIDDATA;
|
||||
}
|
||||
} else if (size <= 3)
|
||||
return 0;
|
||||
st = track->stream;
|
||||
if (st->discard >= AVDISCARD_ALL)
|
||||
return res;
|
||||
|
|
Loading…
Reference in New Issue