ffmpeg | branch: master | Benoit Fouet <benoit.fo...@free.fr> | Fri Nov 21 
09:45:42 2014 +0100| [90c9b494052e6110f43f3db8cc8f6720550b397b] | committer: 
Michael Niedermayer

ffplay: fix mem leak when opening input or parsing options fail.

Reviewed-by: Marton Balint <c...@passwd.hu>
Signed-off-by: Michael Niedermayer <michae...@gmx.at>

> http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=90c9b494052e6110f43f3db8cc8f6720550b397b
---

 ffplay.c |    5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)

diff --git a/ffplay.c b/ffplay.c
index f79161d..1914a66 100644
--- a/ffplay.c
+++ b/ffplay.c
@@ -3169,8 +3169,9 @@ static int read_thread(void *arg)
         stream_component_close(is, is->video_stream);
     if (is->subtitle_stream >= 0)
         stream_component_close(is, is->subtitle_stream);
-    if (is->ic) {
-        avformat_close_input(&is->ic);
+    if (ic) {
+        avformat_close_input(&ic);
+        is->ic = NULL;
     }
 
     if (ret != 0) {

_______________________________________________
ffmpeg-cvslog mailing list
ffmpeg-cvslog@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-cvslog

Reply via email to