diff options
author | James Almer <jamrial@gmail.com> | 2017-04-12 19:38:17 -0300 |
---|---|---|
committer | James Almer <jamrial@gmail.com> | 2017-04-12 19:38:17 -0300 |
commit | 8cd8c8331730fbaac5066bfd66e15b39a85ce537 (patch) | |
tree | b060429c92ce41096353faefee948d4b66b87d2d /libavcodec | |
parent | b905ba5bc18c89c7fccd8621795755644442ef19 (diff) | |
download | ffmpeg-8cd8c8331730fbaac5066bfd66e15b39a85ce537.tar.gz |
avcodec/aacenc_ltp: fix use of uninitialized values
Fixes some valgrind warnings.
Reviewed-by: Rostislav Pehlivanov <atomnuker@gmail.com>
Signed-off-by: James Almer <jamrial@gmail.com>
Diffstat (limited to 'libavcodec')
-rw-r--r-- | libavcodec/aacenc_ltp.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/libavcodec/aacenc_ltp.c b/libavcodec/aacenc_ltp.c index 1bec85b9e3..674a2a0680 100644 --- a/libavcodec/aacenc_ltp.c +++ b/libavcodec/aacenc_ltp.c @@ -74,8 +74,8 @@ void ff_aac_ltp_insert_new_frame(AACEncContext *s) static void get_lag(float *buf, const float *new, LongTermPrediction *ltp) { - int i, j, lag, max_corr = 0; - float max_ratio; + int i, j, lag = 0, max_corr = 0; + float max_ratio = 0.0f; for (i = 0; i < 2048; i++) { float corr, s0 = 0.0f, s1 = 0.0f; const int start = FFMAX(0, i - 1024); |