Commit d12f65f6 authored by Rémi Duraffort's avatar Rémi Duraffort

Fix "Use after free" (CID 248)

parent 2909c5c3
......@@ -178,9 +178,9 @@ libvlc_media_discoverer_new_from_name( libvlc_instance_t * p_inst,
if( !p_mdis->p_sd )
{
free( p_mdis );
libvlc_media_list_release( p_mdis->p_mlist );
libvlc_exception_raise( p_e, "Can't find the services_discovery module named '%s'", psz_name );
free( p_mdis );
return NULL;
}
......@@ -205,9 +205,9 @@ libvlc_media_discoverer_new_from_name( libvlc_instance_t * p_inst,
bool ret = services_discovery_Start( p_mdis->p_sd );
if(!ret)
{
free( p_mdis );
libvlc_media_list_release( p_mdis->p_mlist );
libvlc_exception_raise( p_e, "Can't start the services_discovery module named '%s'", psz_name );
free( p_mdis );
return NULL;
}
......
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