avcodec/parser: use av_freep() to avoid leaving stale pointers in memory
authorMichael Niedermayer <michaelni@gmx.at>
Sat, 1 Nov 2014 09:50:18 +0000 (10:50 +0100)
committerMichael Niedermayer <michaelni@gmx.at>
Sat, 1 Nov 2014 10:36:41 +0000 (11:36 +0100)
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
libavcodec/parser.c

index 55c2f52..d1e1574 100644 (file)
@@ -212,7 +212,7 @@ void av_parser_close(AVCodecParserContext *s)
     if (s) {
         if (s->parser->parser_close)
             s->parser->parser_close(s);
-        av_free(s->priv_data);
+        av_freep(&s->priv_data);
         av_free(s);
     }
 }