[FFmpeg-cvslog] avcodec/acelp_pitch_delay: Fix runtime error: value 4.83233e+39 is outside the range of representable values of type 'float'
Michael Niedermayer
git at videolan.org
Tue Jun 6 01:08:27 EEST 2017
ffmpeg | branch: release/2.8 | Michael Niedermayer <michael at niedermayer.cc> | Tue May 30 04:03:09 2017 +0200| [464288cc5ea891869e9546e1fc3ebeafc9629baa] | committer: Michael Niedermayer
avcodec/acelp_pitch_delay: Fix runtime error: value 4.83233e+39 is outside the range of representable values of type 'float'
Fixes: 1902/clusterfuzz-testcase-minimized-4762451407011840
Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg
Signed-off-by: Michael Niedermayer <michael at niedermayer.cc>
(cherry picked from commit 87bddba43b725d43767f2a387cdea0936ac1b549)
Signed-off-by: Michael Niedermayer <michael at niedermayer.cc>
> http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=464288cc5ea891869e9546e1fc3ebeafc9629baa
---
libavcodec/acelp_pitch_delay.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/libavcodec/acelp_pitch_delay.c b/libavcodec/acelp_pitch_delay.c
index 3ecec01cbe..02a60e4ade 100644
--- a/libavcodec/acelp_pitch_delay.c
+++ b/libavcodec/acelp_pitch_delay.c
@@ -135,7 +135,7 @@ float ff_amr_set_fixed_gain(float fixed_gain_factor, float fixed_mean_energy,
exp2f(M_LOG2_10 * 0.05 *
(avpriv_scalarproduct_float_c(pred_table, prediction_error, 4) +
energy_mean)) /
- sqrtf(fixed_mean_energy);
+ sqrtf(fixed_mean_energy ? fixed_mean_energy : 1.0);
// update quantified prediction error energy history
memmove(&prediction_error[0], &prediction_error[1],
More information about the ffmpeg-cvslog
mailing list