INVALID_SOCKET |
const SOCKET INVALID_SOCKET = -1;
Create an INVALID_SOCKET for platform abstraction.
HOSTENT |
typedef struct hostent HOSTENT;
Create an alias to struct hostent for platform abstraction.
SOCKADDR |
typedef struct sockaddr SOCKADDR;
Create an alias to struct sockaddr for platform abstraction.
SOCKADDR_IN |
typedef struct sockaddr_in SOCKADDR_IN;
Create an alias to struct sockaddr_in for platform abstraction.
SOCKET |
typedef int SOCKET;
Create an alias to int for platform abstraction.
BOOLX |
typedef enum { NO, YES, NOTYET }
In networking, it is possible for operations not to either succeed or fail, but for them to be not ready to complete just yet. This is a tri-state type to convey success, failure, and pending.
- NO
- The operation has failed.
- YES
- The operation has succeeded.
- NOTYET
- The operation can't succeed yet, may never succeed, may fail, but hasn't failed yet.
closesocket |
#define closesocket(x) close(x)
Create an alias to close for platform abstraction.
sleep |
#define sleep(x) Sleep(x*1000)
Create an alias to Sleep for platform abstraction.
(Last Updated 9/24/2004)