cURL / Mailing Lists / curl-library / Single Mail

curl-library

Re: approaching another release

From: Gisle Vanem <gvanem_at_broadpark.no>
Date: Tue, 18 May 2004 19:37:29 +0200

"Joe Halpin" <j.p.h_at_comcast.net> said:
> + /* Make sure sockfd won't overflow the fd_set */
> + if(sockfd >= FD_SETSIZE)
> + return WAITCONN_SELECT_ERROR;
> +

Which assumes sockets are numbered 0 - (FD_SETSIZE-1).
This is not the case on Windows at least, where sockets are
typically > 1000, but FD_SETSIZE is 64. i.e. max 64 sockets
per process.

If libcurl should do anything about this, it should probably
check that # of active sockets are < FD_SETSIZE.

--gv
Received on 2004-05-18