[vlc-commits] Fix memory leak when using subtitles with VDPAU
Devin Heitmueller
git at videolan.org
Mon Sep 22 20:38:06 CEST 2014
vlc | branch: master | Devin Heitmueller <dheitmueller at kernellabs.com> | Sun Sep 21 12:54:55 2014 -0400| [89089ebc9f7625b7317262803394d96139325e54] | committer: Rémi Denis-Courmont
Fix memory leak when using subtitles with VDPAU
When rendering closed captions with VDPAU, nothing frees the subpicture,
causing a leak that bleeds all the memory out of the system within
minutes.
Signed-off-by: Rémi Denis-Courmont <remi at remlab.net>
> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=89089ebc9f7625b7317262803394d96139325e54
---
modules/hw/vdpau/display.c | 6 +++++-
1 file changed, 5 insertions(+), 1 deletion(-)
diff --git a/modules/hw/vdpau/display.c b/modules/hw/vdpau/display.c
index e64fc5e..044ac33 100644
--- a/modules/hw/vdpau/display.c
+++ b/modules/hw/vdpau/display.c
@@ -315,7 +315,11 @@ static void Wait(vout_display_t *vd, picture_t *pic, subpicture_t *subpicture)
}
sys->current = pic;
- (void) subpicture;
+
+ /* We already dealt with the subpicture in the Queue phase, so it's safe to
+ delete at this point */
+ if (subpicture)
+ subpicture_Delete(subpicture);
}
static int Control(vout_display_t *vd, int query, va_list ap)
More information about the vlc-commits
mailing list