mirror of
https://github.com/moparisthebest/curl
synced 2024-12-22 08:08:50 -05:00
multi.c: disambiguate precedence of bitwise and relational operation
This commit is contained in:
parent
0683adbf50
commit
b33074d893
11
lib/multi.c
11
lib/multi.c
@ -1017,10 +1017,13 @@ CURLMcode curl_multi_wait(CURLM *multi_handle,
|
|||||||
/* Add external file descriptions from poll-like struct curl_waitfd */
|
/* Add external file descriptions from poll-like struct curl_waitfd */
|
||||||
for(i = 0; i < extra_nfds; i++) {
|
for(i = 0; i < extra_nfds; i++) {
|
||||||
ufds[nfds].fd = extra_fds[i].fd;
|
ufds[nfds].fd = extra_fds[i].fd;
|
||||||
ufds[nfds].events = (short) (
|
ufds[nfds].events = 0;
|
||||||
((extra_fds[i].events & CURL_WAIT_POLLIN) ? POLLIN : 0) |
|
if(extra_fds[i].events & CURL_WAIT_POLLIN)
|
||||||
((extra_fds[i].events & CURL_WAIT_POLLPRI) ? POLLPRI : 0) |
|
ufds[nfds].events |= POLLIN;
|
||||||
((extra_fds[i].events & CURL_WAIT_POLLOUT) ? POLLOUT : 0) );
|
if(extra_fds[i].events & CURL_WAIT_POLLPRI)
|
||||||
|
ufds[nfds].events |= POLLPRI;
|
||||||
|
if(extra_fds[i].events & CURL_WAIT_POLLOUT)
|
||||||
|
ufds[nfds].events |= POLLOUT;
|
||||||
++nfds;
|
++nfds;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user