1
0
mirror of https://github.com/FFmpeg/FFmpeg.git synced 2025-03-17 20:17:55 +02:00

aacsbr: ensure strictly monotone time borders

This fixes a division by zero in the aac_fixed decoder.

Signed-off-by: Andreas Cadhalpun <Andreas.Cadhalpun@googlemail.com>
(cherry picked from commit ff8816f7172b94028131ee2426ba35e875d973ae)
Signed-off-by: Andreas Cadhalpun <Andreas.Cadhalpun@googlemail.com>
This commit is contained in:
Andreas Cadhalpun 2015-11-08 19:31:00 +01:00
parent dcd837e41c
commit cb44683a8c

View File

@ -718,8 +718,8 @@ static int read_sbr_grid(AACContext *ac, SpectralBandReplication *sbr,
}
for (i = 1; i <= ch_data->bs_num_env; i++) {
if (ch_data->t_env[i-1] > ch_data->t_env[i]) {
av_log(ac->avctx, AV_LOG_ERROR, "Non monotone time borders\n");
if (ch_data->t_env[i-1] >= ch_data->t_env[i]) {
av_log(ac->avctx, AV_LOG_ERROR, "Not strictly monotone time borders\n");
return -1;
}
}