diff options
author | Daniel Stenberg <daniel@haxx.se> | 2004-11-19 08:52:33 +0000 |
---|---|---|
committer | Daniel Stenberg <daniel@haxx.se> | 2004-11-19 08:52:33 +0000 |
commit | 1a05a90f1ce86394d7966aaaa9539adaa228c6bf (patch) | |
tree | 2b9cafe58b4fa7bf01d1b58a23bc5e66157d3279 /lib/url.c | |
parent | dcea109bb5ce1c8afeb0510945eb15e86cfcf1dc (diff) |
David Phillips' FD_SETSIZE fix
Diffstat (limited to 'lib/url.c')
-rw-r--r-- | lib/url.c | 18 |
1 files changed, 2 insertions, 16 deletions
@@ -64,10 +64,6 @@ #include <sys/param.h> #endif -#ifdef HAVE_SYS_SELECT_H -#include <sys/select.h> -#endif - #ifdef VMS #include <in.h> #include <inet.h> @@ -77,9 +73,6 @@ #include <setjmp.h> #endif -#ifndef HAVE_SELECT -#error "We can't compile without select() support!" -#endif #ifndef HAVE_SOCKET #error "We can't compile without socket() support!" #endif @@ -127,6 +120,7 @@ void idn_free (void *ptr); /* prototype from idn-free.h, not provided by #include "content_encoding.h" #include "http_digest.h" #include "http_negotiate.h" +#include "select.h" /* And now for the protocols */ #include "ftp.h" @@ -1552,16 +1546,8 @@ static bool SocketIsDead(curl_socket_t sock) { int sval; bool ret_val = TRUE; - fd_set check_set; - struct timeval to; - - FD_ZERO(&check_set); - FD_SET(sock, &check_set); - - to.tv_sec = 0; - to.tv_usec = 0; - sval = select(sock + 1, &check_set, 0, 0, &to); + sval = Curl_select(sock, CURL_SOCKET_BAD, 0); if(sval == 0) /* timeout */ ret_val = FALSE; |