mirror of
https://gitlab.freedesktop.org/pipewire/pipewire.git
synced 2025-11-04 13:30:12 -05:00
protocol-native: connection: fix errno check condition
The branch should be taken if errno is neither EAGAIN, nor EWOULDBLOCK. Previously, if (errno != EAGAIN || errno != EWOULDBLOCK) would be taken for all values of errno if EAGAIN != EWOULDBLOCK. (Except for the ones that are filtered out before.) Fix that by changing `||` to `&&`.
This commit is contained in:
parent
49846d7550
commit
3c01cfe8f8
1 changed files with 1 additions and 1 deletions
|
|
@ -191,7 +191,7 @@ static int refill_buffer(struct pw_protocol_native_connection *conn, struct buff
|
||||||
else if (len < 0) {
|
else if (len < 0) {
|
||||||
if (errno == EINTR)
|
if (errno == EINTR)
|
||||||
continue;
|
continue;
|
||||||
if (errno != EAGAIN || errno != EWOULDBLOCK)
|
if (errno != EAGAIN && errno != EWOULDBLOCK)
|
||||||
goto recv_error;
|
goto recv_error;
|
||||||
return -EAGAIN;
|
return -EAGAIN;
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue