ffmpeg | branch: master | Michael Niedermayer <[email protected]> | Mon Feb 9 10:05:30 2015 +0100| [48ffaaaaef98640782cfdaaf21319a83292b62b2] | committer: Michael Niedermayer
swresample/x86/rematrix_init: Use av_mallocz_array() Signed-off-by: Michael Niedermayer <[email protected]> > http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=48ffaaaaef98640782cfdaaf21319a83292b62b2 --- libswresample/x86/rematrix_init.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/libswresample/x86/rematrix_init.c b/libswresample/x86/rematrix_init.c index e2ee291..bf69574 100644 --- a/libswresample/x86/rematrix_init.c +++ b/libswresample/x86/rematrix_init.c @@ -50,7 +50,7 @@ av_cold void swri_rematrix_init_x86(struct SwrContext *s){ s->mix_1_1_simd = ff_mix_1_1_a_int16_sse2; s->mix_2_1_simd = ff_mix_2_1_a_int16_sse2; } - s->native_simd_matrix = av_mallocz(2 * num * sizeof(int16_t)); + s->native_simd_matrix = av_mallocz_array(num, 2 * sizeof(int16_t)); s->native_simd_one = av_mallocz(2 * sizeof(int16_t)); for(i=0; i<nb_out; i++){ int sh = 0; @@ -74,7 +74,7 @@ av_cold void swri_rematrix_init_x86(struct SwrContext *s){ s->mix_1_1_simd = ff_mix_1_1_a_float_avx; s->mix_2_1_simd = ff_mix_2_1_a_float_avx; } - s->native_simd_matrix = av_mallocz(num * sizeof(float)); + s->native_simd_matrix = av_mallocz_array(num, sizeof(float)); memcpy(s->native_simd_matrix, s->native_matrix, num * sizeof(float)); s->native_simd_one = av_mallocz(sizeof(float)); memcpy(s->native_simd_one, s->native_one, sizeof(float)); _______________________________________________ ffmpeg-cvslog mailing list [email protected] http://ffmpeg.org/mailman/listinfo/ffmpeg-cvslog
