From d3a4e01137f0930ad1d0301c9f94dca23026b474 Mon Sep 17 00:00:00 2001 From: Andreas Schneider Date: Thu, 17 Jun 2010 11:47:39 +0200 Subject: [PATCH] poll: Fixed another wrong invalid fd check in bsd_poll. --- libssh/poll.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libssh/poll.c b/libssh/poll.c index 7a25f33e..6221e90c 100644 --- a/libssh/poll.c +++ b/libssh/poll.c @@ -111,7 +111,7 @@ static int bsd_poll(ssh_pollfd_t *fds, nfds_t nfds, int timeout) { /* compute fd_sets and find largest descriptor */ for (max_fd = 0, i = 0; i < nfds; i++) { - if (fds[i].fd < 0) { + if (fds[i].fd == (socket_t) -1) { continue; }