From: RĂ©mi Denis-Courmont Date: Sat, 31 May 2008 15:28:54 +0000 (+0300) Subject: Do not use b_die directly, and simplify X-Git-Tag: 0.9.0-test0~513 X-Git-Url: https://git.sesse.net/?a=commitdiff_plain;h=2606ef55873bcd2b1366c161b97d8d693facd26a;p=vlc Do not use b_die directly, and simplify --- diff --git a/src/playlist/engine.c b/src/playlist/engine.c index 89aa16caba..45397c2d24 100644 --- a/src/playlist/engine.c +++ b/src/playlist/engine.c @@ -487,13 +487,10 @@ void playlist_PreparseLoop( playlist_preparse_t *p_obj ) while( vlc_object_alive( p_obj ) ) { - while( p_obj->i_waiting == 0 ) + if( p_obj->i_waiting == 0 ) { - if( vlc_object_wait( p_obj ) || p_playlist->b_die ) - { - vlc_object_unlock( p_obj ); - return; - } + vlc_object_wait( p_obj ); + continue; } p_current = p_obj->pp_waiting[0]; @@ -579,13 +576,10 @@ void playlist_FetcherLoop( playlist_fetcher_t *p_obj ) while( vlc_object_alive( p_obj ) ) { - while( p_obj->i_waiting == 0 ) + if( p_obj->i_waiting == 0 ) { - if( vlc_object_wait( p_obj ) || p_playlist->b_die ) - { - vlc_mutex_unlock( &p_obj->object_lock ); - return; - } + vlc_object_wait( p_obj ); + continue; } p_item = p_obj->pp_waiting[0];