[PATCH] Raise the number of FD on WIN32/CYGWIN as well

Jon TURNEY jon.turney at dronecode.org.uk
Wed Aug 26 07:37:52 PDT 2015


On 26/08/2015 09:13, Olivier Fourdan wrote:
> Sorry, I forgot to amend my commit to indicate this is obviously for "x11proto".
>
> Another point is, I have not tested this change on WIN32/CYGWIN as I don't really use these platforms myself...

The value of FD_SETSIZE for those targets in xserver's configure.ac:403 
probably needs to be increased to match (See the comment on xserver 
commit ed2c2a68)

(The default value of FD_SETSIZE for those targets is only 64)

I'm somewhat sceptical that things work well with >64 clients on those 
targets, but that's a different issue.

> ----- Original Message -----
>> Commit 2c94cdb raised the number of file descriptors from 256 to 512
>> but only for non WIN32/CYGWIN platforms.
>>
>> The definition of XFD_SETSIZE being duplicated, we need to do the same
>> for WIN32/CYGWIN builds as well otherwise a newer X server trying to
>> use more than 256 clients would fail on these platforms.
>>
>> Signed-off-by: Olivier Fourdan <ofourdan at redhat.com>
>> ---
>>   Xpoll.h.in | 2 +-
>>   1 file changed, 1 insertion(+), 1 deletion(-)
>>
>> diff --git a/Xpoll.h.in b/Xpoll.h.in
>> index 01be164..2878591 100644
>> --- a/Xpoll.h.in
>> +++ b/Xpoll.h.in
>> @@ -165,7 +165,7 @@ typedef struct fd_set {
>>
>>   #else /* WIN32 */
>>
>> -#define XFD_SETSIZE	256
>> +#define XFD_SETSIZE	512
>>   #ifndef FD_SETSIZE
>>   #define FD_SETSIZE	XFD_SETSIZE
>>   #endif
>> --
>> 2.4.3


More information about the xorg-devel mailing list