aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMichael Niedermayer <michael@niedermayer.cc>2017-05-08 14:43:03 +0200
committerMichael Niedermayer <michael@niedermayer.cc>2017-05-14 17:48:29 +0200
commit5d7b87af7e26a961bc345329c4bb5ba39fd88d8b (patch)
tree2aca3cf3c22881c4383a5148e6545c108676f0bf
parent2384c67d06ae32a298c3a566537fdbe6c91fde31 (diff)
downloadffmpeg-5d7b87af7e26a961bc345329c4bb5ba39fd88d8b.tar.gz
avcodec/webp: Update canvas size in vp8_lossy_decode_frame() as in vp8_lossless_decode_frame()
Fixes: 1407/clusterfuzz-testcase-minimized-6044604124102656 Fixes: 1420/clusterfuzz-testcase-minimized-6059927359455232 Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/targets/ffmpeg Signed-off-by: Michael Niedermayer <michael@niedermayer.cc> (cherry picked from commit 72810d20b74f05cc4b214d6c277fa6f43160df54) Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
-rw-r--r--libavcodec/webp.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/libavcodec/webp.c b/libavcodec/webp.c
index 3fef45603c..ef7b26c4c8 100644
--- a/libavcodec/webp.c
+++ b/libavcodec/webp.c
@@ -1350,6 +1350,9 @@ static int vp8_lossy_decode_frame(AVCodecContext *avctx, AVFrame *p,
ret = ff_vp8_decode_frame(avctx, p, got_frame, &pkt);
if (ret < 0)
return ret;
+
+ update_canvas_size(avctx, avctx->width, avctx->height);
+
if (s->has_alpha) {
ret = vp8_lossy_decode_alpha(avctx, p, s->alpha_data,
s->alpha_data_size);