From: Sébastien Escudier Date: Thu, 18 Mar 2010 10:31:41 +0000 (+0100) Subject: VLM : move a mutex lock/unlock X-Git-Tag: 1.1.0-pre1~304 X-Git-Url: https://git.sesse.net/?a=commitdiff_plain;h=e17e8321340de0afac7f5d471215692b0ea16f65;p=vlc VLM : move a mutex lock/unlock Signed-off-by: Rémi Denis-Courmont --- diff --git a/src/input/vlm.c b/src/input/vlm.c index 5b61be56a1..bc6756eaa2 100644 --- a/src/input/vlm.c +++ b/src/input/vlm.c @@ -365,12 +365,12 @@ static void* Manage( void* p_object ) int canc = vlc_savecancel (); i_lastcheck = vlm_Date(); + vlc_mutex_lock( &vlm->lock ); while( !vlm->b_die ) { char **ppsz_scheduled_commands = NULL; int i_scheduled_commands = 0; - vlc_mutex_lock( &vlm->lock ); if( i_nextschedule ) vlc_cond_timedwait( &vlm->wait, &vlm->lock, i_nextschedule ); else @@ -474,8 +474,8 @@ static void* Manage( void* p_object ) i_lastcheck = i_time; - vlc_mutex_unlock( &vlm->lock ); } + vlc_mutex_unlock( &vlm->lock ); vlc_restorecancel (canc); return NULL;