Commit 9b467d3c authored by Michael Niedermayer's avatar Michael Niedermayer

examples/transcoding: use av_malloc_array()

Signed-off-by: 's avatarMichael Niedermayer <michaelni@gmx.at>
parent b1763205
...@@ -334,7 +334,7 @@ static int init_filters(void) ...@@ -334,7 +334,7 @@ static int init_filters(void)
const char *filter_spec; const char *filter_spec;
unsigned int i; unsigned int i;
int ret; int ret;
filter_ctx = av_malloc(sizeof(FilteringContext) * ifmt_ctx->nb_streams); filter_ctx = av_malloc_array(ifmt_ctx->nb_streams, sizeof(*filter_ctx));
if (!filter_ctx) if (!filter_ctx)
return AVERROR(ENOMEM); return AVERROR(ENOMEM);
......
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