aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorChristophe Gisquet <christophe.gisquet@gmail.com>2015-03-14 11:48:57 +0000
committerMichael Niedermayer <michaelni@gmx.at>2015-03-14 14:21:27 +0100
commit26bed98d64705348fdc684c2d62c305045dedaec (patch)
treefc39796f7b01a19dab38ea31d327be7838eabc0c
parent480e18e6ff93aed8442084cfb62192c0cb6d0d6e (diff)
downloadffmpeg-26bed98d64705348fdc684c2d62c305045dedaec.tar.gz
ac3_fixed: fix out-of-bound read
Should also improve decoding, but actually doesn't... Signed-off-by: Michael Niedermayer <michaelni@gmx.at> (cherry picked from commit b0834400608b3980c06bf6d2cf747116e60d10c7) Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
-rw-r--r--libavcodec/ac3dec.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/libavcodec/ac3dec.c b/libavcodec/ac3dec.c
index 2f78d73ce8..ce451865db 100644
--- a/libavcodec/ac3dec.c
+++ b/libavcodec/ac3dec.c
@@ -872,7 +872,7 @@ static int decode_audio_block(AC3DecodeContext *s, int blk)
start_subband += start_subband - 7;
end_subband = get_bits(gbc, 3) + 5;
#if USE_FIXED
- s->spx_dst_end_freq = end_freq_inv_tab[end_subband];
+ s->spx_dst_end_freq = end_freq_inv_tab[end_subband-5];
#endif
if (end_subband > 7)
end_subband += end_subband - 7;