[vlc-devel] commit: audio_output: Add a missing lock. (Pierre d'Herbemont )
git version control
git at videolan.org
Sat Aug 9 23:57:42 CEST 2008
vlc | branch: master | Pierre d'Herbemont <pdherbemont at videolan.org> | Sat Aug 9 23:59:40 2008 +0200| [092fa8291552730352911070ea45ffe7fdcb9879] | committer: Pierre d'Herbemont
audio_output: Add a missing lock.
Should fix #1191 (Crash in aout_OutputNextBuffer using auhal on Mac OS X).
> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=092fa8291552730352911070ea45ffe7fdcb9879
---
src/audio_output/mixer.c | 2 ++
1 files changed, 2 insertions(+), 0 deletions(-)
diff --git a/src/audio_output/mixer.c b/src/audio_output/mixer.c
index 0e73a21..b29f2dd 100644
--- a/src/audio_output/mixer.c
+++ b/src/audio_output/mixer.c
@@ -287,8 +287,10 @@ static int MixBuffer( aout_instance_t * p_aout )
if( i_nb_bytes < 0 )
{
/* Is it really the best way to do it ? */
+ vlc_mutex_lock( &p_aout->output_fifo_lock );
aout_FifoSet( p_aout, &p_aout->output.fifo, 0 );
aout_DateSet( &exact_start_date, 0 );
+ vlc_mutex_unlock( &p_aout->output_fifo_lock );
break;
}
More information about the vlc-devel
mailing list