diff mbox series

[FFmpeg-devel,6/6] avfilter/af_aderivative: Free out on error

Message ID 20240609154746.4173264-6-michael@niedermayer.cc
State New
Headers show
Series [FFmpeg-devel,1/6] avutil/hwcontext_d3d11va: correct sizeof AVD3D11FrameDescriptor | expand

Checks

Context Check Description
andriy/make_x86 success Make finished
andriy/make_fate_x86 success Make fate finished

Commit Message

Michael Niedermayer June 9, 2024, 3:47 p.m. UTC
Fixes: CID1197065 Resource leak

Sponsored-by: Sovereign Tech Fund
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
---
 libavfilter/af_aderivative.c | 1 +
 1 file changed, 1 insertion(+)
diff mbox series

Patch

diff --git a/libavfilter/af_aderivative.c b/libavfilter/af_aderivative.c
index eeaa23ff88d..4883972dcf1 100644
--- a/libavfilter/af_aderivative.c
+++ b/libavfilter/af_aderivative.c
@@ -126,6 +126,7 @@  static int filter_frame(AVFilterLink *inlink, AVFrame *in)
         s->prev = ff_get_audio_buffer(inlink, 1);
         if (!s->prev) {
             av_frame_free(&in);
+            av_frame_free(&out);
             return AVERROR(ENOMEM);
         }
     }