VirtualBox

source: vbox/trunk/src/libs/libxml2-2.12.6/include/wsockcompat.h@ 105635

最後變更 在這個檔案從105635是 104106,由 vboxsync 提交於 10 月 前

libxml2-2.9.14: Applied and adjusted our libxml2 changes to 2.9.14. bugref:10640

  • 屬性 svn:eol-style 設為 native
檔案大小: 1.0 KB
 
1/* include/wsockcompat.h
2 * Windows -> Berkeley Sockets compatibility things.
3 */
4
5#if !defined __XML_WSOCKCOMPAT_H__
6#define __XML_WSOCKCOMPAT_H__
7
8#include <errno.h>
9#include <winsock2.h>
10
11/* Fix for old MinGW. */
12#ifndef _WINSOCKAPI_
13#define _WINSOCKAPI_
14#endif
15
16/* the following is a workaround a problem for 'inline' keyword in said
17 header when compiled with Borland C++ 6 */
18#if defined(__BORLANDC__) && !defined(__cplusplus)
19#define inline __inline
20#define _inline __inline
21#endif
22
23#include <ws2tcpip.h>
24
25/* Check if ws2tcpip.h is a recent version which provides getaddrinfo() */
26#if defined(GetAddrInfo)
27#include <wspiapi.h>
28#ifndef SUPPORT_IP6
29 #define SUPPORT_IP6
30#endif
31#endif
32
33#ifndef XML_SOCKLEN_T
34#define XML_SOCKLEN_T int
35#endif
36
37#ifndef ECONNRESET
38#define ECONNRESET WSAECONNRESET
39#endif
40#ifndef EINPROGRESS
41#define EINPROGRESS WSAEINPROGRESS
42#endif
43#ifndef EINTR
44#define EINTR WSAEINTR
45#endif
46#ifndef ESHUTDOWN
47#define ESHUTDOWN WSAESHUTDOWN
48#endif
49#ifndef EWOULDBLOCK
50#define EWOULDBLOCK WSAEWOULDBLOCK
51#endif
52
53#endif /* __XML_WSOCKCOMPAT_H__ */
注意: 瀏覽 TracBrowser 來幫助您使用儲存庫瀏覽器

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