[FFmpeg-cvslog] vp3: Fix double free in vp3_decode_end()

Ronald Bultje git at videolan.org
Thu Jan 17 04:44:32 CET 2013


ffmpeg | branch: release/1.1 | Ronald Bultje <rsbultje at gmail.com> | Thu Jan 10 11:02:57 2013 -0800| [ebd3aa429c38d199f5ee9f578030a3bc6e50056b] | committer: Luca Barbato

vp3: Fix double free in vp3_decode_end()

Signed-off-by: Dale Curtis <dalecurtis at chromium.org>
Signed-off-by: Luca Barbato <lu_zero at gentoo.org>
(cherry picked from commit ec86ba57312745fd7ad9771e3121e79c6aacba30)

Signed-off-by: Luca Barbato <lu_zero at gentoo.org>

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

 libavcodec/vp3.c |   18 +++++++++---------
 1 file changed, 9 insertions(+), 9 deletions(-)

diff --git a/libavcodec/vp3.c b/libavcodec/vp3.c
index 6e85b90..bdd4289 100644
--- a/libavcodec/vp3.c
+++ b/libavcodec/vp3.c
@@ -281,15 +281,15 @@ static av_cold int vp3_decode_end(AVCodecContext *avctx)
     Vp3DecodeContext *s = avctx->priv_data;
     int i;
 
-    av_free(s->superblock_coding);
-    av_free(s->all_fragments);
-    av_free(s->coded_fragment_list[0]);
-    av_free(s->dct_tokens_base);
-    av_free(s->superblock_fragments);
-    av_free(s->macroblock_coding);
-    av_free(s->motion_val[0]);
-    av_free(s->motion_val[1]);
-    av_free(s->edge_emu_buffer);
+    av_freep(&s->superblock_coding);
+    av_freep(&s->all_fragments);
+    av_freep(&s->coded_fragment_list[0]);
+    av_freep(&s->dct_tokens_base);
+    av_freep(&s->superblock_fragments);
+    av_freep(&s->macroblock_coding);
+    av_freep(&s->motion_val[0]);
+    av_freep(&s->motion_val[1]);
+    av_freep(&s->edge_emu_buffer);
 
     if (avctx->internal->is_copy)
         return 0;



More information about the ffmpeg-cvslog mailing list