summaryrefslogtreecommitdiff
path: root/libavformat/tee.c
diff options
context:
space:
mode:
authorAndreas Rheinhardt <andreas.rheinhardt@outlook.com>2021-09-06 02:47:48 +0200
committerAndreas Rheinhardt <andreas.rheinhardt@outlook.com>2021-10-03 20:56:12 +0200
commit3a27fcb168af07f168e58577f6b3696a8fe74803 (patch)
tree9a4d2b9783b6d3a97baf2fadc43259afaa604f2d /libavformat/tee.c
parent4df34df642d252ec7849e07812548c417961f9ec (diff)
avformat/tee: Fix leak of FIFO-options dictionary
Happened for all slaves which didn't use the FIFO. Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>
Diffstat (limited to 'libavformat/tee.c')
-rw-r--r--libavformat/tee.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/libavformat/tee.c b/libavformat/tee.c
index 050c96d326..b358fc2f06 100644
--- a/libavformat/tee.c
+++ b/libavformat/tee.c
@@ -125,6 +125,7 @@ static int close_slave(TeeSlave *tee_slave)
unsigned i;
int ret = 0;
+ av_dict_free(&tee_slave->fifo_options);
avf = tee_slave->avf;
if (!avf)
return 0;
@@ -230,6 +231,7 @@ static int open_slave(AVFormatContext *avf, char *slave, TeeSlave *tee_slave)
av_dict_free(&options);
options = tee_slave->fifo_options;
+ tee_slave->fifo_options = NULL;
}
ret = avformat_alloc_output_context2(&avf2, NULL,
tee_slave->use_fifo ? "fifo" :format, filename);