summaryrefslogtreecommitdiff
path: root/libavformat/fifo.c
diff options
context:
space:
mode:
authorAndreas Rheinhardt <andreas.rheinhardt@outlook.com>2021-07-28 23:23:05 +0200
committerAndreas Rheinhardt <andreas.rheinhardt@outlook.com>2021-08-06 22:50:10 +0200
commit9f19fbba4a84ddff73e32bfe13f0702a4bb40652 (patch)
treed0a9f225b51eb3631d3390db941cbd151d415279 /libavformat/fifo.c
parenta3e78deb0a3a0142d333808678b6ee70873ecab7 (diff)
avformat/fifo: Free dict on av_dict_copy() failure
av_dict_copy() puts the onus on the caller to clean up dst on failure; it can be nonempty if copying a later entry of src fails after having successfully copied an earlier entry. Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>
Diffstat (limited to 'libavformat/fifo.c')
-rw-r--r--libavformat/fifo.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/libavformat/fifo.c b/libavformat/fifo.c
index a9b59b6589..10511167cd 100644
--- a/libavformat/fifo.c
+++ b/libavformat/fifo.c
@@ -129,7 +129,7 @@ static int fifo_thread_write_header(FifoThreadContext *ctx)
ret = av_dict_copy(&format_options, fifo->format_options, 0);
if (ret < 0)
- return ret;
+ goto end;
ret = ff_format_output_open(avf2, avf->url, &format_options);
if (ret < 0) {