> #ifdef WIN32 > #define FD_SETSIZE 1024 /* set before winsock2.h is included */ > #endif /* ! WIN32 */
Windows probably hasn't got sys/select.h at all, so it may not provide this symbol.
Interestingly, it looks like POSIX also requires <sys/time.h> to define FD_SETSIZE. I wonder whether Windows has that header? It'd definitely be better to get this symbol from the system than assume 1024 will work.
Okay, this now makes sense. It just takes the system value and reduces it by 10 to get the MAXCLIENTS value.