This is the mail archive of the
mailing list for the Cygwin project.
RE: FD_SETSIZE and sizeof(fd_set)
- From: Steven Bardwell <SBardwell at lbmsys dot com>
- To: "cygwin at cygwin dot com" <cygwin at cygwin dot com>
- Date: Thu, 23 Jun 2016 10:54:29 +0000
- Subject: RE: FD_SETSIZE and sizeof(fd_set)
- Authentication-results: sourceware.org; auth=none
- Authentication-results: spf=none (sender IP is ) smtp dot mailfrom=SBardwell at lbmsys dot com;
- References: <DM3PR18MB084148FC4EFA327DA33DB267DB2C0 at DM3PR18MB0841 dot namprd18 dot prod dot outlook dot com> <nkf6f4$304$1 at ger dot gmane dot org> <nkfenq$n3h$1 at ger dot gmane dot org>
- Spamdiagnosticmetadata: NSPM
- Spamdiagnosticoutput: 1:99
> > There are (of course) a lot of other included files, and
> > <sys/select.h> is one of them. In my code it comes AFTER the
> > redefinition of FD_SETSIZE and <sys/types.h>. I don't think this
> > could be the issue.
> It is if you are mixing Windows API and Cygwin.
> Just look at sys/select.h and you'll understand.
> René Berber
Here is a "program" that shows the issue I am worried about. It is so simple that I must be overlooking something really obvious:
#define FD_SETSIZE 256
fprintf(stdout, "FD_SETSIZE=%d\n", FD_SETSIZE);
fprintf(stdout, "sizeof(fd_set)=%d\n", sizeof(fd_set));
Problem reports: http://cygwin.com/problems.html
Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple