diff mbox series

[FFmpeg-devel,PATCHv2,2/2] avcoded/fft: Fix memory leak if ctx2 is used

Message ID 20231112174628.2701654-2-sramacher@debian.org
State New
Headers show
Series [FFmpeg-devel,PATCHv2,1/2] avcodec/fft: Use av_mallocz to avoid invalid free/uninit | expand

Checks

Context Check Description
yinshiyou/make_loongarch64 success Make finished
yinshiyou/make_fate_loongarch64 success Make fate finished
andriy/make_x86 success Make finished
andriy/make_fate_x86 success Make fate finished

Commit Message

Sebastian Ramacher Nov. 12, 2023, 5:46 p.m. UTC
---
 libavcodec/avfft.c | 1 +
 1 file changed, 1 insertion(+)
diff mbox series

Patch

diff --git a/libavcodec/avfft.c b/libavcodec/avfft.c
index 3ef076d222..999b5ed79a 100644
--- a/libavcodec/avfft.c
+++ b/libavcodec/avfft.c
@@ -130,6 +130,7 @@  av_cold void av_mdct_end(FFTContext *s)
 {
     if (s) {
         AVTXWrapper *w = (AVTXWrapper *)s;
+        av_tx_uninit(&w->ctx2);
         av_tx_uninit(&w->ctx);
         av_free(w);
     }