Sleep briefly, don't poll when no fds are present
This commit is contained in:
parent
c1c5b22058
commit
a6fe8f392c
@ -193,7 +193,11 @@ retry:
|
||||
}
|
||||
ck_runlock(&ci->lock);
|
||||
|
||||
ret = poll(fds, nfds, 60000);
|
||||
if (!nfds) {
|
||||
cksleep_ms(100);
|
||||
goto retry;
|
||||
}
|
||||
ret = poll(fds, nfds, 1000);
|
||||
if (ret < 0) {
|
||||
if (interrupted())
|
||||
goto retry;
|
||||
|
||||
Loading…
Reference in New Issue
Block a user