Commit 88e49788 authored by Sébastien Escudier's avatar Sébastien Escudier

dereference p_libvlc->p_vlm after the media clean up

parent 7cab5a8c
......@@ -214,16 +214,15 @@ void vlm_Delete( vlm_t *p_vlm )
vlc_mutex_lock( &vlm_mutex );
assert( p_vlm->users > 0 );
if( --p_vlm->users == 0 )
{
assert( libvlc_priv(p_vlm->p_libvlc)->p_vlm == p_vlm );
libvlc_priv(p_vlm->p_libvlc)->p_vlm = NULL;
}
else
p_vlm = NULL;
vlc_mutex_unlock( &vlm_mutex );
if( p_vlm == NULL )
{
vlc_mutex_unlock( &vlm_mutex );
return;
}
/* Destroy and release VLM */
vlc_mutex_lock( &p_vlm->lock );
......@@ -242,6 +241,9 @@ void vlm_Delete( vlm_t *p_vlm )
vlc_object_release( p_vlm->p_vod );
}
libvlc_priv(p_vlm->p_libvlc)->p_vlm = NULL;
vlc_mutex_unlock( &vlm_mutex );
vlc_mutex_lock( &p_vlm->lock_manage );
p_vlm->input_state_changed = true;
vlc_cond_signal( &p_vlm->wait_manage );
......
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