OSDN Git Service

ffprobe: free shared writer context on exit
authorStefano Sabatini <stefasab@gmail.com>
Tue, 3 Dec 2013 20:25:36 +0000 (21:25 +0100)
committerStefano Sabatini <stefasab@gmail.com>
Tue, 3 Dec 2013 20:27:14 +0000 (21:27 +0100)
Fix leak.

Spotted-by: Michael Niedermayer
ffprobe.c

index 43f830b..46c232e 100644 (file)
--- a/ffprobe.c
+++ b/ffprobe.c
@@ -364,6 +364,7 @@ static void writer_close(WriterContext **wctx)
     if ((*wctx)->writer->priv_class)
         av_opt_free((*wctx)->priv);
     av_freep(&((*wctx)->priv));
+    av_opt_free(*wctx);
     av_freep(wctx);
 }