avcodec/dirac_parser: use av_freep(), do not leave stale pointers in memory
authorMichael Niedermayer <michaelni@gmx.at>
Sat, 11 Oct 2014 20:50:51 +0000 (22:50 +0200)
committerMichael Niedermayer <michaelni@gmx.at>
Sat, 11 Oct 2014 20:51:15 +0000 (22:51 +0200)
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
libavcodec/dirac_parser.c

index 8b7c55e..45ded5a 100644 (file)
@@ -251,7 +251,7 @@ static void dirac_parse_close(AVCodecParserContext *s)
     DiracParseContext *pc = s->priv_data;
 
     if (pc->buffer_size > 0)
-        av_free(pc->buffer);
+        av_freep(&pc->buffer);
 }
 
 AVCodecParser ff_dirac_parser = {