mirror of
https://github.com/curl/curl.git
synced 2026-08-25 15:43:47 +03:00
Thanks to this nice summary of poll() implementations:
http://www.greenend.org.uk/rjk/2001/06/poll.html and further tests by Eugene Kotlyarov, we now know that cygwin's poll returns only POLLHUP on remote connection closure so we check for that case (too) and re-enable poll for cygwin builds.
This commit is contained in:
parent
8a712eb5af
commit
c2862742ab
4 changed files with 11 additions and 4 deletions
|
|
@ -104,7 +104,7 @@ int Curl_select(curl_socket_t readfd, curl_socket_t writefd, int timeout_ms)
|
|||
ret = 0;
|
||||
num = 0;
|
||||
if (readfd != CURL_SOCKET_BAD) {
|
||||
if (pfd[num].revents & POLLIN)
|
||||
if (pfd[num].revents & (POLLIN|POLLHUP))
|
||||
ret |= CSELECT_IN;
|
||||
if (pfd[num].revents & POLLERR)
|
||||
ret |= CSELECT_ERR;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue