Mailing-List: contact cygwin-developers-help AT sourceware DOT cygnus DOT com; run by ezmlm List-Subscribe: List-Archive: List-Post: List-Help: , Sender: cygwin-developers-owner AT sources DOT redhat DOT com Delivered-To: mailing list cygwin-developers AT sources DOT redhat DOT com Message-ID: <779F20BCCE5AD31186A50008C75D997917174B@silldn_mail1.sanwaint.com> From: "Fifer, Eric" To: "'cygwin-developers AT sourceware DOT cygnus DOT com'" Subject: poll() fix Date: Mon, 17 Jul 2000 17:59:05 +0100 MIME-Version: 1.0 X-Mailer: Internet Mail Service (5.5.2650.21) Content-Type: text/plain; charset="iso-8859-1" I think that the tests checking the results returned from cygwin_select should not be negated. Regards, Eric Fifer ChangeLog * poll.cc (poll): Fix erroneous negations. --- poll.cc- Mon Jul 17 16:52:15 2000 +++ poll.cc Mon Jul 17 16:53:57 2000 @@ -51,11 +51,11 @@ poll (struct pollfd *fds, unsigned int n else { fds[i].revents = 0; - if (!FD_ISSET (fds[i].fd, &read_fds)) + if (FD_ISSET (fds[i].fd, &read_fds)) fds[i].revents |= POLLIN; - if (!FD_ISSET (fds[i].fd, &write_fds)) + if (FD_ISSET (fds[i].fd, &write_fds)) fds[i].revents |= POLLOUT; - if (!FD_ISSET (fds[i].fd, &except_fds)) + if (FD_ISSET (fds[i].fd, &except_fds)) fds[i].revents |= POLLPRI; } }