* poll.cc (poll): ...but set POLLIN instead.

This commit is contained in:
Corinna Vinschen 2002-11-20 11:00:15 +00:00
parent dbcb75780a
commit 3a366b12f6
2 changed files with 7 additions and 1 deletions

View File

@ -1,3 +1,7 @@
2002-11-20 Steven O'Brien <steven.obrien2@ntlworld.com>
* poll.cc (poll): ...but set POLLIN instead.
2002-11-20 Pierre Humblet <pierre.humblet@ieee.org> 2002-11-20 Pierre Humblet <pierre.humblet@ieee.org>
* security.cc (get_attribute_from_acl): Always test "anti", * security.cc (get_attribute_from_acl): Always test "anti",

View File

@ -111,9 +111,11 @@ poll (struct pollfd *fds, unsigned int nfds, int timeout)
Unfortunately, recvfrom() doesn't make much Unfortunately, recvfrom() doesn't make much
sense then. It returns WSAENOTCONN in that sense then. It returns WSAENOTCONN in that
case. Since that's not actually an error, case. Since that's not actually an error,
we must not set POLLERR. */ we must not set POLLERR but POLLIN. */
if (WSAGetLastError () != WSAENOTCONN) if (WSAGetLastError () != WSAENOTCONN)
fds[i].revents |= POLLERR; fds[i].revents |= POLLERR;
else
fds[i].revents |= POLLIN;
break; break;
case 0: /* Closed on the read side. */ case 0: /* Closed on the read side. */
fds[i].revents |= POLLHUP; fds[i].revents |= POLLHUP;