[vlc-devel] [PATCH 24/40] oldrc: fix reference leak
RĂ©mi Denis-Courmont
remi at remlab.net
Sun May 14 17:45:54 CEST 2017
---
modules/control/oldrc.c | 5 +++--
1 file changed, 3 insertions(+), 2 deletions(-)
diff --git a/modules/control/oldrc.c b/modules/control/oldrc.c
index 37eea02a0f..4f085e4fcc 100644
--- a/modules/control/oldrc.c
+++ b/modules/control/oldrc.c
@@ -1313,8 +1313,9 @@ static int Playlist( vlc_object_t *p_this, char const *psz_cmd,
if( p_item )
{
msg_rc( "trying to enqueue %s to playlist", newval.psz_string );
- if( playlist_AddInput( p_playlist, p_item,
- 0, true ) != VLC_SUCCESS )
+ int ret = playlist_AddInput( p_playlist, p_item, 0, true );
+ input_item_Release( p_item );
+ if( ret != VLC_SUCCESS )
{
return VLC_EGENERIC;
}
--
2.11.0
More information about the vlc-devel
mailing list