Hi,
The poll module fail under Win32 because of the check for FD_SETSIZE.
Windows use a linear array of sockets (of size FD_SETSIZE). The
descriptor value is not used to address the array.
Attached is a patch that fixe this issue.
Regards,
--
Yoann Vandoorselaere | Responsable R&D / CTO | PreludeIDS Technologies
Tel: +33 (0)8 70 70 21 58 Fax: +33(0)4 78 42 21 58
http://www.prelude-ids.com
Index: lib/poll.c
===================================================================
RCS file: /cvsroot/gnulib/gnulib/lib/poll.c,v
retrieving revision 1.6
diff -u -r1.6 poll.c
--- lib/poll.c 3 Jan 2007 10:51:19 -0000 1.6
+++ lib/poll.c 18 Jan 2007 09:30:59 -0000
@@ -133,11 +133,17 @@
| POLLWRNORM | POLLWRBAND)))
{
maxfd = pfd[i].fd;
+ /*
+ * Windows use a linear array of sockets (of size FD_SETSIZE). The
+ * descriptor value is not used to address the array.
+ */
+#if !((defined _WIN32 || defined __WIN32__) && !defined __CYGWIN__)
if (maxfd > FD_SETSIZE)
{
errno = EOVERFLOW;
return -1;
}
+#endif
}
}