From 5a19acb17ceb71657b0eec51dac651953520e5c8 Mon Sep 17 00:00:00 2001 From: Laurent Aimar Date: Sat, 1 Oct 2011 00:45:04 +0200 Subject: Fix out of bound reads in the QDM2 decoder. Signed-off-by: Michael Niedermayer Signed-off-by: Justin Ruggles --- libavcodec/qdm2.c | 2 ++ 1 file changed, 2 insertions(+) (limited to 'libavcodec/qdm2.c') diff --git a/libavcodec/qdm2.c b/libavcodec/qdm2.c index 4c7f881e2b..b68197de17 100644 --- a/libavcodec/qdm2.c +++ b/libavcodec/qdm2.c @@ -1355,6 +1355,8 @@ static void qdm2_fft_decode_tones (QDM2Context *q, int duration, GetBitContext * return; local_int_14 = (offset >> local_int_8); + if (local_int_14 >= FF_ARRAY_ELEMS(fft_level_index_table)) + return; if (q->nb_channels > 1) { channel = get_bits1(gb); -- cgit v1.2.3