Commit 3e606132 authored by Rémi Denis-Courmont's avatar Rémi Denis-Courmont

Memory leaks

parent 6858023f
......@@ -122,15 +122,14 @@ libvlc_instance_t * libvlc_new( int argc, const char *const *argv,
/* Because we probably don't want a GUI by default */
i_ret = libvlc_InternalInit( p_libvlc_int, argc + 1, my_argv );
if( i_ret == VLC_EEXITSUCCESS )
if( i_ret )
{
libvlc_InternalDestroy( p_libvlc_int );
free( p_new );
return NULL;
}
else if( i_ret != 0 )
{
free( p_new );
RAISENULL( "VLC initialization failed" );
if( i_ret == VLC_EEXITSUCCESS )
return NULL;
else
RAISENULL( "VLC initialization failed" );
}
p_new->p_libvlc_int = p_libvlc_int;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment