This is an automated email from the git hooks/post-receive script.

Git pushed a commit to branch release/9.0
in repository ffmpeg.

commit 3b962c40dd511414f04b26fae64fcc8ff349bbd0
Author:     Michael Niedermayer <[email protected]>
AuthorDate: Sat Jul 11 16:59:59 2026 +0200
Commit:     Michael Niedermayer <[email protected]>
CommitDate: Sun Aug 2 02:47:31 2026 +0200

    avfilter/af_arnndn: pad the DCT input buffers to the read length
    
    Fixes: out of array access
    Fixes: SUcVEyk7r3Gc
    Found-by: Kenan Alghythee <[email protected]>
    (cherry picked from commit e38b5d15bd93585f96c75e31e2dd1e1fe9294d05)
    Signed-off-by: Michael Niedermayer <[email protected]>
---
 libavfilter/af_arnndn.c | 6 ++++--
 1 file changed, 4 insertions(+), 2 deletions(-)

diff --git a/libavfilter/af_arnndn.c b/libavfilter/af_arnndn.c
index 5d516f0b15..6209f1b0e0 100644
--- a/libavfilter/af_arnndn.c
+++ b/libavfilter/af_arnndn.c
@@ -1023,7 +1023,7 @@ static int compute_frame_features(AudioRNNContext *s, 
DenoiseState *st, AVComple
     float E = 0;
     float *ceps_0, *ceps_1, *ceps_2;
     float spec_variability = 0;
-    LOCAL_ALIGNED_32(float, Ly, [NB_BANDS]);
+    LOCAL_ALIGNED_32(float, Ly, [FFALIGN(NB_BANDS, 4)]);
     LOCAL_ALIGNED_32(float, p, [WINDOW_SIZE]);
     float pitch_buf[PITCH_BUF_SIZE>>1];
     int pitch_index;
@@ -1057,6 +1057,7 @@ static int compute_frame_features(AudioRNNContext *s, 
DenoiseState *st, AVComple
     for (int i = 0; i < NB_BANDS; i++)
         Exp[i] = Exp[i] / sqrtf(.001f+Ex[i]*Ep[i]);
 
+    memset(Exp + NB_BANDS, 0, (FFALIGN(NB_BANDS, 4) - NB_BANDS) * 
sizeof(*Exp));
     dct(s, tmp, Exp);
 
     for (int i = 0; i < NB_DELTA_CEPS; i++)
@@ -1082,6 +1083,7 @@ static int compute_frame_features(AudioRNNContext *s, 
DenoiseState *st, AVComple
         return 1;
     }
 
+    memset(Ly + NB_BANDS, 0, (FFALIGN(NB_BANDS, 4) - NB_BANDS) * sizeof(*Ly));
     dct(s, features, Ly);
     features[0] -= 12;
     features[1] -= 4;
@@ -1364,7 +1366,7 @@ static float rnnoise_channel(AudioRNNContext *s, 
DenoiseState *st, float *out, c
     AVComplexFloat P[WINDOW_SIZE];
     float x[FRAME_SIZE];
     float Ex[NB_BANDS], Ep[NB_BANDS];
-    LOCAL_ALIGNED_32(float, Exp, [NB_BANDS]);
+    LOCAL_ALIGNED_32(float, Exp, [FFALIGN(NB_BANDS, 4)]);
     float features[NB_FEATURES];
     float g[NB_BANDS];
     float gf[FREQ_SIZE];

_______________________________________________
ffmpeg-cvslog mailing list -- [email protected]
To unsubscribe send an email to [email protected]

Reply via email to