Commit ace2a2a7 authored by Michael Niedermayer's avatar Michael Niedermayer

avcodec/pngdec: Clean up on av_frame_ref() failure

Fixes: memleak
Fixes: 3203/clusterfuzz-testcase-minimized-4514553595428864

Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpegReviewed-by: 's avatarJames Almer <jamrial@gmail.com>
Signed-off-by: 's avatarMichael Niedermayer <michael@niedermayer.cc>
(cherry picked from commit 5480e82d)
Signed-off-by: 's avatarMichael Niedermayer <michael@niedermayer.cc>
parent 53ff525c
......@@ -888,7 +888,7 @@ exit_loop:
metadata = NULL;
if ((ret = av_frame_ref(data, s->picture.f)) < 0)
return ret;
goto the_end;
*got_frame = 1;
......
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