You've already forked FFmpeg
mirror of
https://github.com/FFmpeg/FFmpeg.git
synced 2025-08-15 14:13:16 +02:00
avdevice/lavfi: Use av_malloc_array()
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
This commit is contained in:
@@ -211,7 +211,7 @@ av_cold static int lavfi_read_header(AVFormatContext *avctx)
|
|||||||
}
|
}
|
||||||
|
|
||||||
/* create a sink for each output and connect them to the graph */
|
/* create a sink for each output and connect them to the graph */
|
||||||
lavfi->sinks = av_malloc(sizeof(AVFilterContext *) * avctx->nb_streams);
|
lavfi->sinks = av_malloc_array(avctx->nb_streams, sizeof(AVFilterContext *));
|
||||||
if (!lavfi->sinks)
|
if (!lavfi->sinks)
|
||||||
FAIL(AVERROR(ENOMEM));
|
FAIL(AVERROR(ENOMEM));
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user