From: RĂ©mi Duraffort Date: Sat, 14 Feb 2009 10:06:17 +0000 (+0100) Subject: ncurses: fix a segfault when launching the interface without any item in the playlist. X-Git-Tag: 1.0.0-pre1~649 X-Git-Url: https://git.sesse.net/?a=commitdiff_plain;h=85fb567c408b390422ab72014131ad6ea7754c15;p=vlc ncurses: fix a segfault when launching the interface without any item in the playlist. --- diff --git a/modules/gui/ncurses.c b/modules/gui/ncurses.c index b11542fbcc..569eac8460 100644 --- a/modules/gui/ncurses.c +++ b/modules/gui/ncurses.c @@ -2148,8 +2148,8 @@ static void Redraw( intf_thread_t *p_intf, time_t *t_last_refresh ) playlist_item_t *p_node = p_sys->p_node; int c = ' '; if( ( p_node && p_item->p_input == p_node->p_input ) || - ( !p_node && p_item->p_input == - playlist_CurrentPlayingItem(p_playlist)->p_input ) ) + ( !p_node && playlist_CurrentInput( p_playlist ) && + p_item->p_input == playlist_CurrentPlayingItem(p_playlist)->p_input ) ) c = '*'; else if( p_item == p_node || ( p_item != p_node && PlaylistIsPlaying( p_intf, p_item ) ) )