VirtualBox

source: vbox/trunk/src/VBox/Devices/Graphics/shaderlib/wine/include/mswsock.h@ 85805

Last change on this file since 85805 was 53206, checked in by vboxsync, 10 years ago

Devices/vmsvga: header fixes

  • Property svn:eol-style set to native
  • Property svn:keywords set to Author Date Id Revision
File size: 6.8 KB
Line 
1/*
2 * Copyright (C) the Wine project
3 *
4 * This library is free software; you can redistribute it and/or
5 * modify it under the terms of the GNU Lesser General Public
6 * License as published by the Free Software Foundation; either
7 * version 2.1 of the License, or (at your option) any later version.
8 *
9 * This library is distributed in the hope that it will be useful,
10 * but WITHOUT ANY WARRANTY; without even the implied warranty of
11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
12 * Lesser General Public License for more details.
13 *
14 * You should have received a copy of the GNU Lesser General Public
15 * License along with this library; if not, write to the Free Software
16 * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
17 */
18
19/*
20 * Oracle LGPL Disclaimer: For the avoidance of doubt, except that if any license choice
21 * other than GPL or LGPL is available it will apply instead, Oracle elects to use only
22 * the Lesser General Public License version 2.1 (LGPLv2) at this time for any software where
23 * a choice of LGPL license versions is made available with the language indicating
24 * that LGPLv2 or any later version may be used, or where a choice of which version
25 * of the LGPL is applied is otherwise unspecified.
26 */
27
28#ifndef _MSWSOCK_
29#define _MSWSOCK_
30
31#ifdef __cplusplus
32extern "C" {
33#endif /* defined(__cplusplus) */
34
35#ifdef USE_WS_PREFIX
36#define WS(x) WS_##x
37#else
38#define WS(x) x
39#endif
40
41#ifndef USE_WS_PREFIX
42#define SO_CONNDATA 0x7000
43#define SO_CONNOPT 0x7001
44#define SO_DISCDATA 0x7002
45#define SO_DISCOPT 0x7003
46#define SO_CONNDATALEN 0x7004
47#define SO_CONNOPTLEN 0x7005
48#define SO_DISCDATALEN 0x7006
49#define SO_DISCOPTLEN 0x7007
50#else
51#define WS_SO_CONNDATA 0x7000
52#define WS_SO_CONNOPT 0x7001
53#define WS_SO_DISCDATA 0x7002
54#define WS_SO_DISCOPT 0x7003
55#define WS_SO_CONNDATALEN 0x7004
56#define WS_SO_CONNOPTLEN 0x7005
57#define WS_SO_DISCDATALEN 0x7006
58#define WS_SO_DISCOPTLEN 0x7007
59#endif
60
61#ifndef USE_WS_PREFIX
62#define SO_OPENTYPE 0x7008
63#else
64#define WS_SO_OPENTYPE 0x7008
65#endif
66
67#ifndef USE_WS_PREFIX
68#define SO_SYNCHRONOUS_ALERT 0x10
69#define SO_SYNCHRONOUS_NONALERT 0x20
70#else
71#define WS_SO_SYNCHRONOUS_ALERT 0x10
72#define WS_SO_SYNCHRONOUS_NONALERT 0x20
73#endif
74
75#ifndef USE_WS_PREFIX
76#define SO_MAXDG 0x7009
77#define SO_MAXPATHDG 0x700A
78#define SO_UPDATE_ACCEPT_CONTEXT 0x700B
79#define SO_CONNECT_TIME 0x700C
80#define SO_UPDATE_CONNECT_CONTEXT 0x7010
81#else
82#define WS_SO_MAXDG 0x7009
83#define WS_SO_MAXPATHDG 0x700A
84#define WS_SO_UPDATE_ACCEPT_CONTEXT 0x700B
85#define WS_SO_CONNECT_TIME 0x700C
86#define WS_SO_UPDATE_CONNECT_CONTEXT 0x7010
87#endif
88
89#ifndef USE_WS_PREFIX
90#define TCP_BSDURGENT 0x7000
91#else
92#define WS_TCP_BSDURGENT 0x7000
93#endif
94
95#ifndef USE_WS_PREFIX
96#define SIO_UDP_CONNRESET _WSAIOW(IOC_VENDOR,12)
97#define SIO_SET_COMPATIBILITY_MODE _WSAIOW(IOC_VENDOR,300)
98#else
99#define WS_SIO_UDP_CONNRESET _WSAIOW(WS_IOC_VENDOR,12)
100#define WS_SIO_SET_COMPATIBILITY_MODE _WSAIOW(WS_IOC_VENDOR,300)
101#endif
102
103#define DE_REUSE_SOCKET TF_REUSE_SOCKET
104
105#ifndef USE_WS_PREFIX
106#define MSG_TRUNC 0x0100
107#define MSG_CTRUNC 0x0200
108#define MSG_BCAST 0x0400
109#define MSG_MCAST 0x0800
110#else
111#define WS_MSG_TRUNC 0x0100
112#define WS_MSG_CTRUNC 0x0200
113#define WS_MSG_BCAST 0x0400
114#define WS_MSG_MCAST 0x0800
115#endif
116
117#define TF_DISCONNECT 0x01
118#define TF_REUSE_SOCKET 0x02
119#define TF_WRITE_BEHIND 0x04
120#define TF_USE_DEFAULT_WORKER 0x00
121#define TF_USE_SYSTEM_THREAD 0x10
122#define TF_USE_KERNEL_APC 0x20
123
124#define TP_DISCONNECT TF_DISCONNECT
125#define TP_REUSE_SOCKET TF_REUSE_SOCKET
126#define TP_USE_DEFAULT_WORKER TF_USE_DEFAULT_WORKER
127#define TP_USE_SYSTEM_THREAD TF_USE_SYSTEM_THREAD
128#define TP_USE_KERNEL_APC TF_USE_KERNEL_APC
129
130#define TP_ELEMENT_MEMORY 1
131#define TP_ELEMENT_FILE 2
132#define TP_ELEMENT_EOP 4
133
134#define WSAID_ACCEPTEX \
135 {0xb5367df1,0xcbac,0x11cf,{0x95,0xca,0x00,0x80,0x5f,0x48,0xa1,0x92}}
136#define WSAID_CONNECTEX \
137 {0x25a207b9,0xddf3,0x4660,{0x8e,0xe9,0x76,0xe5,0x8c,0x74,0x06,0x3e}}
138#define WSAID_DISCONNECTEX \
139 {0x7fda2e11,0x8630,0x436f,{0xa0,0x31,0xf5,0x36,0xa6,0xee,0xc1,0x57}}
140#define WSAID_GETACCEPTEXSOCKADDRS \
141 {0xb5367df2,0xcbac,0x11cf,{0x95,0xca,0x00,0x80,0x5f,0x48,0xa1,0x92}}
142#define WSAID_TRANSMITFILE \
143 {0xb5367df0,0xcbac,0x11cf,{0x95,0xca,0x00,0x80,0x5f,0x48,0xa1,0x92}}
144#define WSAID_TRANSMITPACKETS \
145 {0xd9689da0,0x1f90,0x11d3,{0x99,0x71,0x00,0xc0,0x4f,0x68,0xc8,0x76}}
146#define WSAID_WSARECVMSG \
147 {0xf689d7c8,0x6f1f,0x436b,{0x8a,0x53,0xe5,0x4f,0xe3,0x51,0xc3,0x22}}
148#define WSAID_WSASENDMSG \
149 {0xa441e712,0x754f,0x43ca,{0x84,0xa7,0x0d,0xee,0x44,0xcf,0x60,0x6d}}
150
151typedef struct _TRANSMIT_FILE_BUFFERS {
152 LPVOID Head;
153 DWORD HeadLength;
154 LPVOID Tail;
155 DWORD TailLength;
156} TRANSMIT_FILE_BUFFERS, *PTRANSMIT_FILE_BUFFERS, *LPTRANSMIT_FILE_BUFFERS;
157
158typedef struct _TRANSMIT_PACKETS_ELEMENT {
159 ULONG dwElFlags;
160 ULONG cLength;
161 union {
162 struct {
163 LARGE_INTEGER nFileOffset;
164 HANDLE hFile;
165 } DUMMYSTRUCTNAME;
166 PVOID pBuffer;
167 } DUMMYUNIONNAME;
168} TRANSMIT_PACKETS_ELEMENT, *PTRANSMIT_PACKETS_ELEMENT, *LPTRANSMIT_PACKETS_ELEMENT;
169
170typedef struct _WSACMSGHDR {
171 SIZE_T cmsg_len;
172 INT cmsg_level;
173 INT cmsg_type;
174 /* followed by UCHAR cmsg_data[] */
175} WSACMSGHDR, *PWSACMSGHDR, *LPWSACMSGHDR;
176
177typedef BOOL (WINAPI * LPFN_ACCEPTEX)(SOCKET, SOCKET, PVOID, DWORD, DWORD, DWORD, LPDWORD, LPOVERLAPPED);
178typedef BOOL (WINAPI * LPFN_CONNECTEX)(SOCKET, const struct WS(sockaddr) *, int, PVOID, DWORD, LPDWORD, LPOVERLAPPED);
179typedef BOOL (WINAPI * LPFN_DISCONNECTEX)(SOCKET, LPOVERLAPPED, DWORD, DWORD);
180typedef VOID (WINAPI * LPFN_GETACCEPTEXSOCKADDRS)(PVOID, DWORD, DWORD, DWORD, struct WS(sockaddr) **, LPINT, struct WS(sockaddr) **, LPINT);
181typedef BOOL (WINAPI * LPFN_TRANSMITFILE)(SOCKET, HANDLE, DWORD, DWORD, LPOVERLAPPED, LPTRANSMIT_FILE_BUFFERS, DWORD);
182typedef BOOL (WINAPI * LPFN_TRANSMITPACKETS)(SOCKET, LPTRANSMIT_PACKETS_ELEMENT, DWORD, DWORD, LPOVERLAPPED, DWORD);
183typedef INT (WINAPI * LPFN_WSARECVMSG)(SOCKET, LPWSAMSG, LPDWORD, LPWSAOVERLAPPED, LPWSAOVERLAPPED_COMPLETION_ROUTINE);
184typedef INT (WINAPI * LPFN_WSASENDMSG)(SOCKET, LPWSAMSG, DWORD, LPDWORD, LPWSAOVERLAPPED, LPWSAOVERLAPPED_COMPLETION_ROUTINE);
185
186BOOL WINAPI AcceptEx(SOCKET, SOCKET, PVOID, DWORD, DWORD, DWORD, LPDWORD, LPOVERLAPPED);
187VOID WINAPI GetAcceptExSockaddrs(PVOID, DWORD, DWORD, DWORD, struct WS(sockaddr) **, LPINT, struct WS(sockaddr) **, LPINT);
188BOOL WINAPI TransmitFile(SOCKET, HANDLE, DWORD, DWORD, LPOVERLAPPED, LPTRANSMIT_FILE_BUFFERS, DWORD);
189INT WINAPI WSARecvEx(SOCKET, char *, INT, INT *);
190
191#ifdef __cplusplus
192}
193#endif
194
195#undef WS
196
197#endif /* _MSWSOCK_ */
Note: See TracBrowser for help on using the repository browser.

© 2025 Oracle Support Privacy / Do Not Sell My Info Terms of Use Trademark Policy Automated Access Etiquette