[FFmpeg-cvslog] takdec: fix initialisation of LOCAL_ALIGNED array

Mans Rullgard git at videolan.org
Sat Dec 8 16:40:07 CET 2012


ffmpeg | branch: master | Mans Rullgard <mans at mansr.com> | Fri Dec  7 22:13:57 2012 +0000| [cd71af90a92def2cc9c1dd3753958f348fb4868f] | committer: Mans Rullgard

takdec: fix initialisation of LOCAL_ALIGNED array

When LOCAL_ALIGNED uses manual alignment initialisation is not
possible.

Signed-off-by: Mans Rullgard <mans at mansr.com>

> http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=cd71af90a92def2cc9c1dd3753958f348fb4868f
---

 libavcodec/takdec.c |    4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

diff --git a/libavcodec/takdec.c b/libavcodec/takdec.c
index 87fcf83..0ac870c 100644
--- a/libavcodec/takdec.c
+++ b/libavcodec/takdec.c
@@ -420,11 +420,13 @@ static void decode_filter_coeffs(TAKDecContext *s, int filter_order, int size,
 static int decode_subframe(TAKDecContext *s, int32_t *decoded,
                            int subframe_size, int prev_subframe_size)
 {
-    LOCAL_ALIGNED_16(int16_t, filter, [MAX_PREDICTORS]) = { 0, };
+    LOCAL_ALIGNED_16(int16_t, filter, [MAX_PREDICTORS]);
     GetBitContext *gb = &s->gb;
     int i, ret;
     int dshift, size, filter_quant, filter_order;
 
+    memset(filter, 0, MAX_PREDICTORS * sizeof(*filter));
+
     if (!get_bits1(gb))
         return decode_residues(s, decoded, subframe_size);
 



More information about the ffmpeg-cvslog mailing list