aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMichael Niedermayer <michael@niedermayer.cc>2017-03-16 11:20:46 +0100
committerMichael Niedermayer <michael@niedermayer.cc>2017-05-17 20:35:19 +0200
commitfd5f35746112bc760c214451c9dbeae4b02b2d94 (patch)
treeb33cca71507fee32758451a992b5c9e72d806af3
parent72b968361b3d8cb2e0429d6a7a4443bd25b75505 (diff)
downloadffmpeg-fd5f35746112bc760c214451c9dbeae4b02b2d94.tar.gz
avcodec/vp56: Check avctx->error_concealment before enabling EC
Fixes timeout with 847/clusterfuzz-testcase-5291877358108672 Fixes timeout with 850/clusterfuzz-testcase-5721296509861888 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 98da63b3f5f5a277c5c3a16860db9a9f6741e54c) Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
-rw-r--r--libavcodec/vp56.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/libavcodec/vp56.c b/libavcodec/vp56.c
index 9d4162bb96..bfc3d3bc7c 100644
--- a/libavcodec/vp56.c
+++ b/libavcodec/vp56.c
@@ -712,7 +712,7 @@ static int ff_vp56_decode_mbs(AVCodecContext *avctx, void *data,
int ret = vp56_decode_mb(s, mb_row, mb_col, is_alpha);
if (ret < 0) {
damaged = 1;
- if (!s->have_undamaged_frame) {
+ if (!s->have_undamaged_frame || !avctx->error_concealment) {
s->discard_frame = 1;
return AVERROR_INVALIDDATA;
}