[FFmpeg-cvslog] avcodec/aic: Use av_malloc_array

Michael Niedermayer git at videolan.org
Wed Jan 7 21:56:19 CET 2015


ffmpeg | branch: master | Michael Niedermayer <michaelni at gmx.at> | Wed Jan  7 19:46:16 2015 +0100| [86e7d20ac2e7cfd6385f84e78117058c1ea0882f] | committer: Michael Niedermayer

avcodec/aic: Use av_malloc_array

Signed-off-by: Michael Niedermayer <michaelni at gmx.at>

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

 libavcodec/aic.c |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/libavcodec/aic.c b/libavcodec/aic.c
index 3472301..e5e2236 100644
--- a/libavcodec/aic.c
+++ b/libavcodec/aic.c
@@ -448,7 +448,7 @@ static av_cold int aic_decode_init(AVCodecContext *avctx)
         }
     }
 
-    ctx->slice_data = av_malloc(ctx->slice_width * AIC_BAND_COEFFS
+    ctx->slice_data = av_malloc_array(ctx->slice_width, AIC_BAND_COEFFS
                                 * sizeof(*ctx->slice_data));
     if (!ctx->slice_data) {
         av_log(avctx, AV_LOG_ERROR, "Error allocating slice buffer\n");



More information about the ffmpeg-cvslog mailing list