Commit 58a53123 authored by Michael Niedermayer's avatar Michael Niedermayer

avcodec/vble: use av_malloc_array()

Signed-off-by: 's avatarMichael Niedermayer <michaelni@gmx.at>
parent 7999b41d
...@@ -189,7 +189,7 @@ static av_cold int vble_decode_init(AVCodecContext *avctx) ...@@ -189,7 +189,7 @@ static av_cold int vble_decode_init(AVCodecContext *avctx)
ctx->size = avpicture_get_size(avctx->pix_fmt, ctx->size = avpicture_get_size(avctx->pix_fmt,
avctx->width, avctx->height); avctx->width, avctx->height);
ctx->val = av_malloc(ctx->size * sizeof(*ctx->val)); ctx->val = av_malloc_array(ctx->size, sizeof(*ctx->val));
if (!ctx->val) { if (!ctx->val) {
av_log(avctx, AV_LOG_ERROR, "Could not allocate values buffer.\n"); av_log(avctx, AV_LOG_ERROR, "Could not allocate values buffer.\n");
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment