don't handle EINTR and EAGAIN as the same

EAGAIN means a non-blocking operation would block and we should not
try again right away but leave the loop and wait instead.

See #358
This commit is contained in:
Wim Taymans 2020-11-02 16:43:56 +01:00
parent e094640c7b
commit c43026d93e
8 changed files with 10 additions and 10 deletions

View file

@ -1345,7 +1345,7 @@ int sm_media_session_roundtrip(struct sm_media_session *sess)
pw_loop_enter(loop);
while (!done) {
if ((res = pw_loop_iterate(loop, -1)) < 0) {
if (res == -EINTR || res == -EAGAIN)
if (res == -EINTR)
continue;
pw_log_warn(NAME" %p: iterate error %d (%s)",
loop, res, spa_strerror(res));