Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/FFmpeg/FFmpeg.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPaul B Mahol <onemda@gmail.com>2019-10-02 11:54:45 +0300
committerPaul B Mahol <onemda@gmail.com>2019-10-02 11:54:45 +0300
commit9847380f5f5a3850ecc9f32fa310a7e5e3f703f7 (patch)
tree149b975688807f7b846c81fe79777501670776e2 /libavfilter/vf_elbg.c
parentc4de49edc4652e2f17c8747a6dd9b36ff362017a (diff)
avfilter/vf_elbg: stop leaking frame on error
Diffstat (limited to 'libavfilter/vf_elbg.c')
-rw-r--r--libavfilter/vf_elbg.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/libavfilter/vf_elbg.c b/libavfilter/vf_elbg.c
index 396af82f77..b59da9ec85 100644
--- a/libavfilter/vf_elbg.c
+++ b/libavfilter/vf_elbg.c
@@ -178,8 +178,10 @@ static int filter_frame(AVFilterLink *inlink, AVFrame *frame)
AVFrame *out = ff_get_video_buffer(outlink, outlink->w, outlink->h);
uint32_t *pal;
- if (!out)
+ if (!out) {
+ av_frame_free(&frame);
return AVERROR(ENOMEM);
+ }
out->pts = frame->pts;
av_frame_free(&frame);
pal = (uint32_t *)out->data[1];