From 991cf95fdeebc3aff34c3dd094df0589f7a02f68 Mon Sep 17 00:00:00 2001 From: Steven Liu Date: Thu, 10 Oct 2019 10:07:53 +0800 Subject: avformat/rtmpproto: fix memleak when open rtmp failed Signed-off-by: Steven Liu --- libavformat/rtmpproto.c | 3 +++ 1 file changed, 3 insertions(+) (limited to 'libavformat/rtmpproto.c') diff --git a/libavformat/rtmpproto.c b/libavformat/rtmpproto.c index eb08d4d424..42c6b94ea0 100644 --- a/libavformat/rtmpproto.c +++ b/libavformat/rtmpproto.c @@ -2880,6 +2880,9 @@ reconnect: return 0; fail: + av_freep(&rt->playpath); + av_freep(&rt->tcurl); + av_freep(&rt->flashver); av_dict_free(opts); rtmp_close(s); return ret; -- cgit v1.2.3