poll: FD_SETSIZE is only for the count value of FD_SET on Windows.

This commit is contained in:
Andreas Schneider
2010-07-06 00:39:34 +02:00
parent c1729c36d9
commit 59a95fc3a7

View File

@@ -124,10 +124,12 @@ static int bsd_poll(ssh_pollfd_t *fds, nfds_t nfds, int timeout) {
if (fds[i].fd == SSH_INVALID_SOCKET) {
continue;
}
#ifndef _WIN32
if (fds[i].fd >= FD_SETSIZE) {
rc = -1;
break;
}
#endif
if (fds[i].events & (POLLIN | POLLRDNORM)) {
FD_SET (fds[i].fd, &readfds);