aboutsummaryrefslogtreecommitdiffstats
path: root/libavcodec
diff options
context:
space:
mode:
authorMichael Niedermayer <michael@niedermayer.cc>2019-07-26 00:35:32 +0200
committerMichael Niedermayer <michael@niedermayer.cc>2020-01-06 11:30:42 +0100
commit731b4f7414b7ee5e2b90b55d6721c2df0dc4f160 (patch)
tree6a7bca20ee6a2d954738a13ae3902242c9a64dc9 /libavcodec
parente7c8bc5ae0195135b8750d549ed49cd9032335d5 (diff)
downloadffmpeg-731b4f7414b7ee5e2b90b55d6721c2df0dc4f160.tar.gz
avcodec/vqavideo: Set video size
Fixes: out of array access Fixes: 15919/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_VQA_fuzzer-5657368257363968 Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg Signed-off-by: Michael Niedermayer <michael@niedermayer.cc> (cherry picked from commit 02f909dc24b1f05cfbba75077c7707b905e63cd2) Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
Diffstat (limited to 'libavcodec')
-rw-r--r--libavcodec/vqavideo.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/libavcodec/vqavideo.c b/libavcodec/vqavideo.c
index 0e70be1000..b9743abda9 100644
--- a/libavcodec/vqavideo.c
+++ b/libavcodec/vqavideo.c
@@ -147,7 +147,7 @@ static av_cold int vqa_decode_init(AVCodecContext *avctx)
}
s->width = AV_RL16(&s->avctx->extradata[6]);
s->height = AV_RL16(&s->avctx->extradata[8]);
- if ((ret = av_image_check_size(s->width, s->height, 0, avctx)) < 0) {
+ if ((ret = ff_set_dimensions(avctx, s->width, s->height)) < 0) {
s->width= s->height= 0;
return ret;
}