Backport ALSA fix, r3990.

Originally committed to SVN as r3991.
This commit is contained in:
Grigori Goronzy 2010-01-15 23:01:36 +00:00
parent baa1721a0c
commit 998c42c4a1
1 changed files with 3 additions and 0 deletions

View File

@ -223,6 +223,9 @@ void AlsaPlayer::SetUpAsync()
// And free struct again
snd_pcm_sw_params_free(sw_params);
// Prepare for playback
snd_pcm_prepare(pcm_handle);
// Attach async handler
if (snd_async_add_pcm_handler(&pcm_callback, pcm_handle, async_write_handler, this) < 0) {
throw _T("ALSA player: Failed attaching async handler");