[vlc-commits] avcodec: fix memory leak of rec->pict.data[1]

Hannes Domani git at videolan.org
Tue Dec 15 14:28:13 CET 2015


vlc | branch: master | Hannes Domani <ssbssa at yahoo.de> | Sun Dec 13 16:16:10 2015 +0100| [3bb208b2e37bfc1c441077fac056554458e58a3f] | committer: Jean-Baptiste Kempf

avcodec: fix memory leak of rec->pict.data[1]

Signed-off-by: Jean-Baptiste Kempf <jb at videolan.org>

> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=3bb208b2e37bfc1c441077fac056554458e58a3f
---

 modules/codec/avcodec/subtitle.c |    5 +----
 1 file changed, 1 insertion(+), 4 deletions(-)

diff --git a/modules/codec/avcodec/subtitle.c b/modules/codec/avcodec/subtitle.c
index 5cfad1b..de4d3e4 100644
--- a/modules/codec/avcodec/subtitle.c
+++ b/modules/codec/avcodec/subtitle.c
@@ -299,11 +299,8 @@ static subpicture_t *ConvertSubtitle(decoder_t *dec, AVSubtitle *ffsub, mtime_t
             *region_next = region;
             region_next = &region->p_next;
         }
-        /* Free AVSubtitleRect */
-        avpicture_free(&rec->pict);
-        av_free(rec);
     }
-    av_free(ffsub->rects);
+    avsubtitle_free(ffsub);
 
     return spu;
 }



More information about the vlc-commits mailing list