diff options
author | Michael Niedermayer <michaelni@gmx.at> | 2014-04-08 16:15:32 +0200 |
---|---|---|
committer | Michael Niedermayer <michaelni@gmx.at> | 2014-04-08 16:15:32 +0200 |
commit | e4c180c05ac9aed33c16ee6e89581a9f2f7b890f (patch) | |
tree | f249ea8611d705c8ee1bb687d4c2abcf6be1c375 | |
parent | 53487268e55538badf47b6a0fd138fadc87d93bb (diff) | |
download | ffmpeg-e4c180c05ac9aed33c16ee6e89581a9f2f7b890f.tar.gz |
avcodec/a64multienc: use av_malloc(z)_array()
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
-rw-r--r-- | libavcodec/a64multienc.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/libavcodec/a64multienc.c b/libavcodec/a64multienc.c index af3f965213..306777418d 100644 --- a/libavcodec/a64multienc.c +++ b/libavcodec/a64multienc.c @@ -220,9 +220,9 @@ static av_cold int a64multi_encode_init(AVCodecContext *avctx) a64_palette[mc_colors[a]][2] * 0.11; } - if (!(c->mc_meta_charset = av_malloc(32000 * c->mc_lifetime * sizeof(int))) || + if (!(c->mc_meta_charset = av_malloc_array(c->mc_lifetime, 32000 * sizeof(int))) || !(c->mc_best_cb = av_malloc(CHARSET_CHARS * 32 * sizeof(int))) || - !(c->mc_charmap = av_mallocz(1000 * c->mc_lifetime * sizeof(int))) || + !(c->mc_charmap = av_mallocz_array(c->mc_lifetime, 1000 * sizeof(int))) || !(c->mc_colram = av_mallocz(CHARSET_CHARS * sizeof(uint8_t))) || !(c->mc_charset = av_malloc(0x800 * (INTERLACED+1) * sizeof(uint8_t)))) { av_log(avctx, AV_LOG_ERROR, "Failed to allocate buffer memory.\n"); |