Commit 9be4d7c0 authored by Jean-Paul Saman's avatar Jean-Paul Saman

Fix deadlock while quiting VLC. It can get stuck in the playlist. Stopping the...

Fix deadlock while quiting VLC. It can get stuck in the playlist. Stopping the playlist first resolves this problem.
parent 393c3c57
/*****************************************************************************
* hotkeys.c: Hotkey handling for vlc
*****************************************************************************
* Copyright (C) 2004 VideoLAN
* Copyright (C) 2005 VideoLAN
* $Id$
*
* Authors: Sigmund Augdal <sigmunau@idi.ntnu.no>
......@@ -253,6 +253,14 @@ static void Run( intf_thread_t *p_intf )
if( i_action == ACTIONID_QUIT )
{
p_playlist = vlc_object_find( p_intf, VLC_OBJECT_PLAYLIST,
FIND_ANYWHERE );
if( p_playlist )
{
playlist_Stop( p_playlist );
vlc_object_release( p_playlist );
}
/* Playlist is stopped now kill vlc. */
p_intf->p_vlc->b_die = VLC_TRUE;
ClearChannels( p_intf, p_vout );
vout_OSDMessage( p_intf, DEFAULT_CHAN, _( "Quit" ) );
......
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