diff options
author | Luca Barbato <lu_zero@gentoo.org> | 2013-06-20 11:36:04 +0200 |
---|---|---|
committer | Luca Barbato <lu_zero@gentoo.org> | 2013-06-22 20:54:59 +0200 |
commit | f963f701d90bd7bb03e39aab4e59bd137084e082 (patch) | |
tree | 2dc05318c96625ad5c36a7628182684419f0cadc | |
parent | 42cc6cefd315c1556e2a52f7ebe2f766ec82b790 (diff) | |
download | ffmpeg-f963f701d90bd7bb03e39aab4e59bd137084e082.tar.gz |
ogg: relax demuxer conformance checks
Some samples in the wild are missing headers that are expected by the
specification but in practice do not affect decoding.
-rw-r--r-- | libavformat/oggdec.c | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/libavformat/oggdec.c b/libavformat/oggdec.c index d8f89b8f80..2ab730190c 100644 --- a/libavformat/oggdec.c +++ b/libavformat/oggdec.c @@ -478,8 +478,11 @@ static int ogg_get_headers(AVFormatContext *s) if (os->codec && os->codec->nb_header && os->nb_header < os->codec->nb_header) { av_log(s, AV_LOG_ERROR, - "Headers mismatch for stream %d\n", i); - return AVERROR_INVALIDDATA; + "Headers mismatch for stream %d: " + "expected %d received %d.\n", + i, os->codec->nb_header, os->nb_header); + if (s->error_recognition & AV_EF_EXPLODE) + return AVERROR_INVALIDDATA; } if (os->start_granule != OGG_NOGRANULE_VALUE) os->lastpts = s->streams[i]->start_time = |