--------------------- PatchSet 3006 Date: 2001/09/10 20:25:56 Author: serassio Branch: nt-2_3 Tag: (none) Log: Updated configure files, some cosmetic changes Members: include/squid-mswin.h:1.1->1.1.2.1 --- /dev/null Wed Feb 14 00:55:00 2007 +++ squid/include/squid-mswin.h Wed Feb 14 00:55:10 2007 @@ -0,0 +1,78 @@ +/* Some tricks for MS Compilers */ +#define alloca _alloca +#define chdir _chdir +#define getcwd _getcwd +#define getpid _getpid +#define setmode _setmode +#define snprintf _snprintf +#define strcasecmp _stricmp +#define strncasecmp _strnicmp +#define vsnprintf _vsnprintf +#define O_BYNARY _O_BINARY +#define O_TEXT _O_TEXT +#define S_IRWXO 007 +#define S_ISDIR(m) (((m) & _S_IFDIR) == _S_IFDIR) +#define ushort unsigned short int +#define uid_t int +#define gid_t int + +#define CHANGE_FD_SETSIZE 1 +#if CHANGE_FD_SETSIZE && SQUID_MAXFD > DEFAULT_FD_SETSIZE +#define FD_SETSIZE SQUID_MAXFD +#endif + +#include +#include +#include "readdir.h" + +typedef char *caddr_t; +#undef FD_CLOSE +#undef FD_OPEN +#undef FD_READ +#undef FD_WRITE +#define EISCONN WSAEISCONN +#define EINPROGRESS WSAEINPROGRESS +#define EWOULDBLOCK WSAEWOULDBLOCK +#define EALREADY WSAEALREADY +#define ETIMEDOUT WSAETIMEDOUT + +#if defined (COMM_C) || defined (COMM_SELECT_C) +#define recv(x,y,z) recv(x,y,z,0) +#define send(x,y,z) send(x,y,z,0) +#define fd_bytes(x,y,z) sd_bytes(x,y,z) +#define fd_note(x,y) sd_note(x,y) +#define fd_open(x,y,z) sd_open(x,y,z) +#define fd_close(x) sd_close(x) +#define ignoreErrno(x) WSAignoreErrno(x) +#endif + +#if defined (ICP_V2_C) +#define fd_note(x,y) sd_note(x,y) +#define ignoreErrno(x) WSAignoreErrno(x) +#define commSetSelect(x,y,z,u,v) commSetSelectS(x,y,z,u,v) +#endif + +#if defined (SNMP_CORE_C) +#define fd_note(x,y) sd_note(x,y) +#define commSetSelect(x,y,z,u,v) commSetSelectS(x,y,z,u,v) +#endif + +#if defined(WHOIS_C) || defined(WAIS_C) +#define send(x,y,z) send(x,y,z,0) +#define recv(x,y,z) recv(x,y,z,0) +#define fd_bytes(x,y,z) sd_bytes(x,y,z) +#define ignoreErrno(x) WSAignoreErrno(x) +#define commSetSelect(x,y,z,u,v) commSetSelectS(x,y,z,u,v) +#endif + +#if defined (SSL_C) || defined (PCONN_C) || defined (PUMP_C) || \ + defined (HTTP_C) || defined (HTCP_C) || defined (HELPER_C) || defined (CLIENT_SIDE_C) \ + || defined (FTP_C) || defined (GOPHER_C) || defined(IDENT_C) || \ + defined (ICMP_C) || defined (FORWARD_C) || defined (DNS_INTERNAL_C) +#define recv(x,y,z) recv(x,y,z,0) +#define send(x,y,z) send(x,y,z,0) +#define fd_bytes(x,y,z) sd_bytes(x,y,z) +#define fd_note(x,y) sd_note(x,y) +#define ignoreErrno(x) WSAignoreErrno(x) +#define commSetSelect(x,y,z,u,v) commSetSelectS(x,y,z,u,v) +#endif