[FFmpeg-cvslog] avcodec/avpicture: use av_freep(), do not leave stale pointers in memory

Michael Niedermayer git at videolan.org
Wed Oct 8 16:16:18 CEST 2014


ffmpeg | branch: master | Michael Niedermayer <michaelni at gmx.at> | Wed Oct  8 16:09:31 2014 +0200| [f703c8cc0901f199455d848434d8932765dd2e5d] | committer: Michael Niedermayer

avcodec/avpicture: use av_freep(), do not leave stale pointers in memory

Signed-off-by: Michael Niedermayer <michaelni at gmx.at>

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

 libavcodec/avpicture.c |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/libavcodec/avpicture.c b/libavcodec/avpicture.c
index a6f89ef..0484dc3 100644
--- a/libavcodec/avpicture.c
+++ b/libavcodec/avpicture.c
@@ -66,7 +66,7 @@ int avpicture_alloc(AVPicture *picture,
 
 void avpicture_free(AVPicture *picture)
 {
-    av_free(picture->data[0]);
+    av_freep(&picture->data[0]);
 }
 
 void av_picture_copy(AVPicture *dst, const AVPicture *src,



More information about the ffmpeg-cvslog mailing list