You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

61 lines
2.1 KiB

7 years ago
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
  1. /* include/wsockcompat.h
  2. * Windows -> Berkeley Sockets compatibility things.
  3. */
  4. #if !defined __XML_WSOCKCOMPAT_H__
  5. #define __XML_WSOCKCOMPAT_H__
  6. #ifdef _WIN32_WCE
  7. #include <winsock.h>
  8. #else
  9. #undef HAVE_ERRNO_H
  10. #include <winsock2.h>
  11. #endif
  12. #if !defined SOCKLEN_T
  13. #define SOCKLEN_T int
  14. #endif
  15. #define EWOULDBLOCK WSAEWOULDBLOCK
  16. #define EINPROGRESS WSAEINPROGRESS
  17. #define EALREADY WSAEALREADY
  18. #define ENOTSOCK WSAENOTSOCK
  19. #define EDESTADDRREQ WSAEDESTADDRREQ
  20. #define EMSGSIZE WSAEMSGSIZE
  21. #define EPROTOTYPE WSAEPROTOTYPE
  22. #define ENOPROTOOPT WSAENOPROTOOPT
  23. #define EPROTONOSUPPORT WSAEPROTONOSUPPORT
  24. #define ESOCKTNOSUPPORT WSAESOCKTNOSUPPORT
  25. #define EOPNOTSUPP WSAEOPNOTSUPP
  26. #define EPFNOSUPPORT WSAEPFNOSUPPORT
  27. #define EAFNOSUPPORT WSAEAFNOSUPPORT
  28. #define EADDRINUSE WSAEADDRINUSE
  29. #define EADDRNOTAVAIL WSAEADDRNOTAVAIL
  30. #define ENETDOWN WSAENETDOWN
  31. #define ENETUNREACH WSAENETUNREACH
  32. #define ENETRESET WSAENETRESET
  33. #define ECONNABORTED WSAECONNABORTED
  34. #define ECONNRESET WSAECONNRESET
  35. #define ENOBUFS WSAENOBUFS
  36. #define EISCONN WSAEISCONN
  37. #define ENOTCONN WSAENOTCONN
  38. #define ESHUTDOWN WSAESHUTDOWN
  39. #define ETOOMANYREFS WSAETOOMANYREFS
  40. #define ETIMEDOUT WSAETIMEDOUT
  41. #define ECONNREFUSED WSAECONNREFUSED
  42. #define ELOOP WSAELOOP
  43. #define EHOSTDOWN WSAEHOSTDOWN
  44. #define EHOSTUNREACH WSAEHOSTUNREACH
  45. #define EPROCLIM WSAEPROCLIM
  46. #define EUSERS WSAEUSERS
  47. #define EDQUOT WSAEDQUOT
  48. #define ESTALE WSAESTALE
  49. #define EREMOTE WSAEREMOTE
  50. /* These cause conflicts with the codes from errno.h. Since they are
  51. not used in the relevant code (nanoftp, nanohttp), we can leave
  52. them disabled.
  53. #define ENAMETOOLONG WSAENAMETOOLONG
  54. #define ENOTEMPTY WSAENOTEMPTY
  55. */
  56. #endif /* __XML_WSOCKCOMPAT_H__ */