Mercurial > audlegacy-plugins
changeset 3175:1bb4cad57923
alsa-ng: alsaplug_flush(): It is good practise to lock the same mutex as the waiting threads while calling g_cond_broadcast.
author | Tomasz Mon <desowin@gmail.com> |
---|---|
date | Sat, 16 May 2009 15:41:43 +0200 |
parents | 8106e1b31115 |
children | dca77b467ea2 |
files | src/alsa-ng/alsa-core.c |
diffstat | 1 files changed, 1 insertions(+), 1 deletions(-) [+] |
line wrap: on
line diff
--- a/src/alsa-ng/alsa-core.c Fri May 15 16:12:30 2009 -0500 +++ b/src/alsa-ng/alsa-core.c Sat May 16 15:41:43 2009 +0200 @@ -281,8 +281,8 @@ /* make the request... */ g_mutex_lock(pcm_state_mutex); flush_request = time; + g_cond_broadcast(pcm_state_cond); g_mutex_unlock(pcm_state_mutex); - g_cond_broadcast(pcm_state_cond); /* ...then wait for the transaction to complete. */ g_mutex_lock(pcm_state_mutex);