avcodec/diracdec: Fix Assertion frame->buf[0] failed at libavcodec/decode.c:610

Fixes: 1487/clusterfuzz-testcase-minimized-6288036495097856

Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/targets/ffmpeg
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
This commit is contained in:
Michael Niedermayer 2017-05-11 23:24:23 +02:00
parent d05bdba242
commit 6899e6e560
1 changed files with 1 additions and 1 deletions

View File

@ -2047,9 +2047,9 @@ static int get_delayed_pic(DiracContext *s, AVFrame *picture, int *got_frame)
if (out) {
out->reference ^= DELAYED_PIC_REF;
*got_frame = 1;
if((ret = av_frame_ref(picture, out->avframe)) < 0)
return ret;
*got_frame = 1;
}
return 0;