1 #ifndef __WINE_WINE_WINSOCK16_H
2 #define __WINE_WINE_WINSOCK16_H
7 typedef UINT16 SOCKET16;
11 UINT16 fd_count; /* how many are SET? */
12 SOCKET16 fd_array[FD_SETSIZE]; /* an array of SOCKETs */
15 /* ws_hostent16, ws_protoent16, ws_servent16, ws_netent16
16 * are 1-byte aligned here ! */
17 typedef struct ws_hostent16
19 SEGPTR h_name; /* official name of host */
20 SEGPTR h_aliases; /* alias list */
21 INT16 h_addrtype; /* host address type */
22 INT16 h_length; /* length of address */
23 SEGPTR h_addr_list; /* list of addresses from name server */
26 typedef struct ws_protoent16
28 SEGPTR p_name; /* official protocol name */
29 SEGPTR p_aliases; /* alias list */
30 INT16 p_proto; /* protocol # */
33 typedef struct ws_servent16
35 SEGPTR s_name; /* official service name */
36 SEGPTR s_aliases; /* alias list */
37 INT16 s_port; /* port # */
38 SEGPTR s_proto; /* protocol to use */
41 typedef struct ws_netent16
43 SEGPTR n_name; /* official name of net */
44 SEGPTR n_aliases; /* alias list */
45 INT16 n_addrtype; /* net address type */
46 INT n_net; /* network # */
51 #define WS_FD_CLR16(fd, set) __WS_FD_CLR((fd),(set), ws_fd_set16)
52 #define WS_FD_SET16(fd, set) __WS_FD_SET((fd),(set), ws_fd_set16)
53 #define WS_FD_ZERO16(set) (((ws_fd_set16*)(set))->fd_count=0)
54 #define WS_FD_ISSET16(fd, set) __WSAFDIsSet16((SOCKET16)(fd), (ws_fd_set16*)(set))
56 #define INVALID_SOCKET16 ((SOCKET16)(~0))
58 INT16 WINAPI __WSAFDIsSet16( SOCKET16, ws_fd_set16 * );
59 INT16 WINAPI WSAStartup16(UINT16 wVersionRequired, LPWSADATA lpWSAData);
60 void WINAPI WSASetLastError16(INT16 iError);
61 INT16 WINAPI WSAUnhookBlockingHook16(void);
62 FARPROC16 WINAPI WSASetBlockingHook16(FARPROC16 lpBlockFunc);
63 HANDLE16 WINAPI WSAAsyncGetServByName16(HWND16 hWnd, UINT16 wMsg, LPCSTR name, LPCSTR proto,
64 SEGPTR buf, INT16 buflen);
65 HANDLE16 WINAPI WSAAsyncGetServByPort16(HWND16 hWnd, UINT16 wMsg, INT16 port,
66 LPCSTR proto, SEGPTR buf, INT16 buflen);
67 HANDLE16 WINAPI WSAAsyncGetProtoByName16(HWND16 hWnd, UINT16 wMsg,
68 LPCSTR name, SEGPTR buf, INT16 buflen);
69 HANDLE16 WINAPI WSAAsyncGetProtoByNumber16(HWND16 hWnd, UINT16 wMsg,
70 INT16 number, SEGPTR buf, INT16 buflen);
71 HANDLE16 WINAPI WSAAsyncGetHostByName16(HWND16 hWnd, UINT16 wMsg,
72 LPCSTR name, SEGPTR buf, INT16 buflen);
73 HANDLE16 WINAPI WSAAsyncGetHostByAddr16(HWND16 hWnd, UINT16 wMsg, LPCSTR addr,
74 INT16 len, INT16 type, SEGPTR buf, INT16 buflen);
75 INT16 WINAPI WSACancelAsyncRequest16(HANDLE16 hAsyncTaskHandle);
76 INT16 WINAPI WSAAsyncSelect16(SOCKET16 s, HWND16 hWnd, UINT16 wMsg, LONG lEvent);
77 INT16 WINAPI WSARecvEx16(SOCKET16 s, char *buf, INT16 len, INT16 *flags);
79 #endif /* __WINE_WINE_WINSOCK16_H */