From 2a44c4bc9e2623e623981efe9f2510a45fce84f1 Mon Sep 17 00:00:00 2001 From: Andreas Rheinhardt Date: Sat, 22 Jul 2023 20:28:25 +0200 Subject: [PATCH] fftools/ffmpeg_mux_init: Fix leak on error Fixes Coverity issue #1539098. Reviewed-by: Anton Khirnov Signed-off-by: Andreas Rheinhardt --- fftools/ffmpeg_mux_init.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/fftools/ffmpeg_mux_init.c b/fftools/ffmpeg_mux_init.c index 86521417ec..0289cdabad 100644 --- a/fftools/ffmpeg_mux_init.c +++ b/fftools/ffmpeg_mux_init.c @@ -361,7 +361,7 @@ static int enc_stats_init(OutputStream *ost, EncStats *es, int pre, ret = GROW_ARRAY(es->components, es->nb_components); if (ret < 0) - return ret; + goto fail; c = &es->components[es->nb_components - 1];