From fb86750a674a5e335a0f90fe6dfe6efdda6698b3 Mon Sep 17 00:00:00 2001 From: wm4 Date: Mon, 17 Nov 2014 20:07:59 +0100 Subject: ao_alsa: check for EAGAIN too Simply retry on EAGAIN. I've seen this in several other projects; it might be just cargo-culting though. --- audio/out/ao_alsa.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/audio/out/ao_alsa.c b/audio/out/ao_alsa.c index 8d85a0a660..b857c8fcf4 100644 --- a/audio/out/ao_alsa.c +++ b/audio/out/ao_alsa.c @@ -656,7 +656,7 @@ static int play(struct ao *ao, void **data, int samples, int flags) res = snd_pcm_writei(p->alsa, data[0], samples); } - if (res == -EINTR) { + if (res == -EINTR || res == -EAGAIN) { /* nothing to do */ res = 0; } else if (res == -ESTRPIPE) { /* suspend */ -- cgit v1.2.3