This is an automated email from the git hooks/post-receive script.
Git pushed a commit to branch master
in repository ffmpeg.
The following commit(s) were added to refs/heads/master by this push:
new e38b5d15bd avfilter/af_arnndn: pad the DCT input buffers to the read
length
e38b5d15bd is described below
commit e38b5d15bd93585f96c75e31e2dd1e1fe9294d05
Author: Michael Niedermayer <[email protected]>
AuthorDate: Sat Jul 11 16:59:59 2026 +0200
Commit: michaelni <[email protected]>
CommitDate: Fri Jul 31 04:00:18 2026 +0000
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]>
---
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]