Return correct error in snd_pcm_wait() after snd_pcm_poll_descriptors() call

This commit is contained in:
Jaroslav Kysela 2004-11-12 20:27:31 +00:00
parent 4f6da0fe88
commit 2d7ca56e2a

View file

@ -2094,6 +2094,8 @@ int snd_pcm_wait(snd_pcm_t *pcm, int timeout)
} }
} }
err = snd_pcm_poll_descriptors(pcm, &pfd, 1); err = snd_pcm_poll_descriptors(pcm, &pfd, 1);
if (err < 0)
return err;
assert(err == 1); assert(err == 1);
__retry: __retry:
err_poll = poll(&pfd, 1, timeout); err_poll = poll(&pfd, 1, timeout);