[FFmpeg-devel] [PATCH] avformat/avio: Use ffurl_closep

Andreas Rheinhardt andreas.rheinhardt at gmail.com
Fri Nov 29 11:42:48 EET 2019


Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt at gmail.com>
---
 libavformat/avio.c | 3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)

diff --git a/libavformat/avio.c b/libavformat/avio.c
index c1bad312cd..2dd2312296 100644
--- a/libavformat/avio.c
+++ b/libavformat/avio.c
@@ -346,8 +346,7 @@ int ffurl_open_whitelist(URLContext **puc, const char *filename, int flags,
     if (!ret)
         return 0;
 fail:
-    ffurl_close(*puc);
-    *puc = NULL;
+    ffurl_closep(puc);
     return ret;
 }
 
-- 
2.21.0



More information about the ffmpeg-devel mailing list