mirror of
https://github.com/alsa-project/alsa-lib.git
synced 2025-10-29 05:40:25 -04:00
PCM API - handle EINTR from poll() in snd_pcm_wait() function
This commit is contained in:
parent
62b9d00ad6
commit
745062ee01
1 changed files with 4 additions and 1 deletions
|
|
@ -2240,8 +2240,11 @@ int snd_pcm_wait_nocheck(snd_pcm_t *pcm, int timeout)
|
|||
}
|
||||
do {
|
||||
err_poll = poll(pfd, npfds, timeout);
|
||||
if (err_poll < 0)
|
||||
if (err_poll < 0) {
|
||||
if (errno == EINTR)
|
||||
continue;
|
||||
return -errno;
|
||||
}
|
||||
if (! err_poll)
|
||||
break;
|
||||
err = snd_pcm_poll_descriptors_revents(pcm, pfd, npfds, revents);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue