summaryrefslogtreecommitdiffstats
path: root/winsup/cygwin/poll.cc
diff options
context:
space:
mode:
authorChristopher Faylor <me@cgf.cx>2002-09-22 03:38:57 +0000
committerChristopher Faylor <me@cgf.cx>2002-09-22 03:38:57 +0000
commitc90e1cf179187d5d188a3003db503ffd86d80cfe (patch)
treead0890e2267f00de92aefc5a99d60017e4f15fe9 /winsup/cygwin/poll.cc
parent228f6b6e07f1b08620dc08f389263f228da0079f (diff)
downloadcygnal-c90e1cf179187d5d188a3003db503ffd86d80cfe.tar.gz
cygnal-c90e1cf179187d5d188a3003db503ffd86d80cfe.tar.bz2
cygnal-c90e1cf179187d5d188a3003db503ffd86d80cfe.zip
* fhandler.cc (fhandler_base::dup): Don't set handle on failure. Caller has
already taken care of that. * fhandler_console.cc (fhandler_console::open): Initialize handles to NULL. (fhandler_console::close): Ditto. GNUify non-GNU formatted functions calls throughout.
Diffstat (limited to 'winsup/cygwin/poll.cc')
-rw-r--r--winsup/cygwin/poll.cc8
1 files changed, 4 insertions, 4 deletions
diff --git a/winsup/cygwin/poll.cc b/winsup/cygwin/poll.cc
index 36c61cfcc..3c61c565e 100644
--- a/winsup/cygwin/poll.cc
+++ b/winsup/cygwin/poll.cc
@@ -35,7 +35,7 @@ poll (struct pollfd *fds, unsigned int nfds, int timeout)
if (fds[i].fd > max_fd)
max_fd = fds[i].fd;
- size_t fds_size = howmany(max_fd + 1, NFDBITS) * sizeof (fd_mask);
+ size_t fds_size = howmany (max_fd + 1, NFDBITS) * sizeof (fd_mask);
read_fds = (fd_set *) alloca (fds_size);
write_fds = (fd_set *) alloca (fds_size);
@@ -55,7 +55,7 @@ poll (struct pollfd *fds, unsigned int nfds, int timeout)
for (unsigned int i = 0; i < nfds; ++i)
{
fds[i].revents = 0;
- if (!cygheap->fdtab.not_open(fds[i].fd))
+ if (!cygheap->fdtab.not_open (fds[i].fd))
{
if (fds[i].events & POLLIN)
FD_SET(fds[i].fd, read_fds);
@@ -81,7 +81,7 @@ poll (struct pollfd *fds, unsigned int nfds, int timeout)
{
if (fds[i].fd >= 0)
{
- if (cygheap->fdtab.not_open(fds[i].fd))
+ if (cygheap->fdtab.not_open (fds[i].fd))
fds[i].revents = POLLHUP;
else
{
@@ -93,7 +93,7 @@ poll (struct pollfd *fds, unsigned int nfds, int timeout)
if (!sock)
fds[i].revents |= POLLIN;
else
- switch (sock->recvfrom (peek, sizeof(peek), MSG_PEEK,
+ switch (sock->recvfrom (peek, sizeof (peek), MSG_PEEK,
NULL, NULL))
{
case -1: /* Something weird happened */