Commit b5a87dc1 authored by Michael Niedermayer's avatar Michael Niedermayer

Merge commit 'c4abc909'

* commit 'c4abc909':
  vqavideo: check the version

Conflicts:
	libavcodec/vqavideo.c

See: b226af39Merged-by: 's avatarMichael Niedermayer <michaelni@gmx.at>
parents f982d006 c4abc909
......@@ -134,8 +134,15 @@ static av_cold int vqa_decode_init(AVCodecContext *avctx)
/* load up the VQA parameters from the header */
s->vqa_version = s->avctx->extradata[0];
if (s->vqa_version < 1 || s->vqa_version > 3) {
av_log(s->avctx, AV_LOG_ERROR, "unsupported version %d\n", s->vqa_version);
switch (s->vqa_version) {
case 1:
case 2:
break;
case 3:
avpriv_report_missing_feature(avctx, "VQA Version %d", s->vqa_version);
return AVERROR_PATCHWELCOME;
default:
avpriv_request_sample(avctx, "VQA Version %i", s->vqa_version);
return AVERROR_PATCHWELCOME;
}
s->width = AV_RL16(&s->avctx->extradata[6]);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment