[vlc-devel] commit: libvlc_mediacontrol: fix object leaks. ( Rémi Duraffort )
git version control
git at videolan.org
Mon Aug 17 15:55:14 CEST 2009
vlc | branch: master | Rémi Duraffort <ivoire at videolan.org> | Mon Aug 17 15:42:25 2009 +0200| [3a0036f042773f6755650a5db24275ef7bea65c5] | committer: Rémi Duraffort
libvlc_mediacontrol: fix object leaks.
> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=3a0036f042773f6755650a5db24275ef7bea65c5
---
src/control/mediacontrol_audio_video.c | 6 ++++++
1 files changed, 6 insertions(+), 0 deletions(-)
diff --git a/src/control/mediacontrol_audio_video.c b/src/control/mediacontrol_audio_video.c
index 46e6da4..330e90c 100644
--- a/src/control/mediacontrol_audio_video.c
+++ b/src/control/mediacontrol_audio_video.c
@@ -85,6 +85,7 @@ mediacontrol_snapshot( mediacontrol_Instance *self,
if( vout_GetSnapshot( p_vout, &p_image, NULL, &fmt, "png", 500*1000 ) )
{
+ vlc_object_release( p_vout );
RAISE_NULL( mediacontrol_InternalException, "Snapshot exception" );
return NULL;
}
@@ -109,6 +110,8 @@ mediacontrol_snapshot( mediacontrol_Instance *self,
if( !p_pic )
RAISE_NULL( mediacontrol_InternalException, "Out of memory" );
+
+ vlc_object_release( p_vout );
return p_pic;
}
@@ -150,6 +153,9 @@ mediacontrol_display_text( mediacontrol_Instance *self,
RAISE_VOID( mediacontrol_InternalException, "No input" );
}
p_vout = input_GetVout( p_input );
+ /*FIXME: take care of the next fixme that can use p_input */
+ vlc_object_release( p_input );
+
if( ! p_vout )
{
RAISE_VOID( mediacontrol_InternalException, "No video output" );
More information about the vlc-devel
mailing list