[vlc-commits] ALSA: open in blocking mode since we want blocking mode

Rémi Denis-Courmont git at videolan.org
Wed Apr 13 19:36:04 CEST 2011


vlc | branch: master | Rémi Denis-Courmont <remi at remlab.net> | Wed Apr 13 19:43:57 2011 +0300| [6262431ce3fe8a9e08cc346f3c549b9a0094b033] | committer: Rémi Denis-Courmont

ALSA: open in blocking mode since we want blocking mode

> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=6262431ce3fe8a9e08cc346f3c549b9a0094b033
---

 modules/audio_output/alsa.c |    5 +----
 1 files changed, 1 insertions(+), 4 deletions(-)

diff --git a/modules/audio_output/alsa.c b/modules/audio_output/alsa.c
index 0d5dd78..ca2e91b 100644
--- a/modules/audio_output/alsa.c
+++ b/modules/audio_output/alsa.c
@@ -436,7 +436,7 @@ static int Open( vlc_object_t *p_this )
     /* Open the device */
     msg_Dbg( p_aout, "opening ALSA device `%s'", psz_device );
     int val = snd_pcm_open (&p_sys->p_snd_pcm, psz_device,
-                            SND_PCM_STREAM_PLAYBACK, SND_PCM_NONBLOCK);
+                            SND_PCM_STREAM_PLAYBACK, 0);
     if (val != 0)
     {
         msg_Err (p_aout, "cannot open ALSA device `%s' (%s)",
@@ -450,9 +450,6 @@ static int Open( vlc_object_t *p_this )
     }
     free( psz_device );
 
-    /* We want blocking mode */
-    snd_pcm_nonblock( p_sys->p_snd_pcm, 0 );
-
     snd_pcm_uframes_t i_buffer_size;
     snd_pcm_uframes_t i_period_size;
     int i_channels;



More information about the vlc-commits mailing list