[FFmpeg-devel] [PATCH 8/9] avfilter/vf_subtitles: Return early upon avformat_open_input() failure
Andreas Rheinhardt
andreas.rheinhardt at gmail.com
Fri Sep 11 00:49:00 EEST 2020
There is nothing to free at this point.
Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt at gmail.com>
---
libavfilter/vf_subtitles.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/libavfilter/vf_subtitles.c b/libavfilter/vf_subtitles.c
index 08b4d4efca..f9733c3935 100644
--- a/libavfilter/vf_subtitles.c
+++ b/libavfilter/vf_subtitles.c
@@ -322,7 +322,7 @@ static av_cold int init_subtitles(AVFilterContext *ctx)
ret = avformat_open_input(&fmt, ass->filename, NULL, NULL);
if (ret < 0) {
av_log(ctx, AV_LOG_ERROR, "Unable to open %s\n", ass->filename);
- goto end;
+ return ret;
}
ret = avformat_find_stream_info(fmt, NULL);
if (ret < 0)
--
2.20.1
More information about the ffmpeg-devel
mailing list