D:/opendownloadmanager/ODM-1.x/InetFile/cURL_lib/select.c File Reference

#include "setup.h"
#include <curl/curl.h>
#include "urldata.h"
#include "connect.h"
#include "select.h"

Go to the source code of this file.

Defines

#define VALID_SOCK(s)   (((s) >= 0) && ((s) < FD_SETSIZE))
#define VERIFY_SOCK(x)
#define VALID_NFDS(n)   (((n) >= 0) && ((n) <= FD_SETSIZE))
#define VERIFY_NFDS(x)
#define elapsed_ms   (int)curlx_tvdiff(curlx_tvnow(), initial_tv)
#define error_is_EINTR   (0)
#define SMALL_POLLNFDS   0x20

Functions

static int wait_ms (int timeout_ms)
int Curl_socket_ready (curl_socket_t readfd, curl_socket_t writefd, int timeout_ms)
int Curl_poll (struct pollfd ufds[], unsigned int nfds, int timeout_ms)


Define Documentation

#define elapsed_ms   (int)curlx_tvdiff(curlx_tvnow(), initial_tv)

Definition at line 76 of file select.c.

Referenced by CreateConnection(), Curl_poll(), Curl_socket_ready(), and wait_ms().

#define error_is_EINTR   (0)

Definition at line 81 of file select.c.

Referenced by Curl_poll(), Curl_socket_ready(), and wait_ms().

#define SMALL_POLLNFDS   0x20

Definition at line 84 of file select.c.

#define VALID_NFDS ( n   )     (((n) >= 0) && ((n) <= FD_SETSIZE))

Definition at line 65 of file select.c.

#define VALID_SOCK (  )     (((s) >= 0) && ((s) < FD_SETSIZE))

Definition at line 58 of file select.c.

#define VERIFY_NFDS (  ) 

Value:

do { \
  if(!VALID_NFDS(x)) { \
    SET_SOCKERRNO(EINVAL); \
    return -1; \
  } \
} while(0)

Definition at line 66 of file select.c.

#define VERIFY_SOCK (  ) 

Value:

do { \
  if(!VALID_SOCK(x)) { \
    SET_SOCKERRNO(EINVAL); \
    return -1; \
  } \
} while(0)

Definition at line 59 of file select.c.

Referenced by Curl_poll(), and Curl_socket_ready().


Function Documentation

int Curl_poll ( struct pollfd  ufds[],
unsigned int  nfds,
int  timeout_ms 
)

int Curl_socket_ready ( curl_socket_t  readfd,
curl_socket_t  writefd,
int  timeout_ms 
)

static int wait_ms ( int  timeout_ms  )  [static]


Generated on Sun May 25 00:20:09 2008 by  doxygen 1.5.6