input/alsa: call snd_pcm_start() after snd_pcm_prepare()
This is necessary because we'll never get woken up again by epoll_wait() after a buffer overrun recovery, unless we start the PCM explicitly before returning to the I/O loop.
This commit is contained in:
parent
ef114ee6cb
commit
92684112ed
|
@ -267,6 +267,8 @@ AlsaInputStream::Recover(int err)
|
|||
case SND_PCM_STATE_SETUP:
|
||||
case SND_PCM_STATE_XRUN:
|
||||
err = snd_pcm_prepare(capture_handle);
|
||||
if (err == 0)
|
||||
err = snd_pcm_start(capture_handle);
|
||||
break;
|
||||
|
||||
case SND_PCM_STATE_DISCONNECTED:
|
||||
|
|
Loading…
Reference in New Issue