WSAError.cs 5.9 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131
  1. namespace Ryujinx.HLE.Utilities
  2. {
  3. enum WSAError
  4. {
  5. /*
  6. * All Windows Sockets error constants are biased by WSABASEERR from
  7. * the "normal"
  8. */
  9. WSABASEERR = 10000,
  10. /*
  11. * Windows Sockets definitions of regular Microsoft C error constants
  12. */
  13. WSAEINTR = (WSABASEERR + 4),
  14. WSAEBADF = (WSABASEERR + 9),
  15. WSAEACCES = (WSABASEERR + 13),
  16. WSAEFAULT = (WSABASEERR + 14),
  17. WSAEINVAL = (WSABASEERR + 22),
  18. WSAEMFILE = (WSABASEERR + 24),
  19. /*
  20. * Windows Sockets definitions of regular Berkeley error constants
  21. */
  22. WSAEWOULDBLOCK = (WSABASEERR + 35),
  23. WSAEINPROGRESS = (WSABASEERR + 36),
  24. WSAEALREADY = (WSABASEERR + 37),
  25. WSAENOTSOCK = (WSABASEERR + 38),
  26. WSAEDESTADDRREQ = (WSABASEERR + 39),
  27. WSAEMSGSIZE = (WSABASEERR + 40),
  28. WSAEPROTOTYPE = (WSABASEERR + 41),
  29. WSAENOPROTOOPT = (WSABASEERR + 42),
  30. WSAEPROTONOSUPPORT = (WSABASEERR + 43),
  31. WSAESOCKTNOSUPPORT = (WSABASEERR + 44),
  32. WSAEOPNOTSUPP = (WSABASEERR + 45),
  33. WSAEPFNOSUPPORT = (WSABASEERR + 46),
  34. WSAEAFNOSUPPORT = (WSABASEERR + 47),
  35. WSAEADDRINUSE = (WSABASEERR + 48),
  36. WSAEADDRNOTAVAIL = (WSABASEERR + 49),
  37. WSAENETDOWN = (WSABASEERR + 50),
  38. WSAENETUNREACH = (WSABASEERR + 51),
  39. WSAENETRESET = (WSABASEERR + 52),
  40. WSAECONNABORTED = (WSABASEERR + 53),
  41. WSAECONNRESET = (WSABASEERR + 54),
  42. WSAENOBUFS = (WSABASEERR + 55),
  43. WSAEISCONN = (WSABASEERR + 56),
  44. WSAENOTCONN = (WSABASEERR + 57),
  45. WSAESHUTDOWN = (WSABASEERR + 58),
  46. WSAETOOMANYREFS = (WSABASEERR + 59),
  47. WSAETIMEDOUT = (WSABASEERR + 60),
  48. WSAECONNREFUSED = (WSABASEERR + 61),
  49. WSAELOOP = (WSABASEERR + 62),
  50. WSAENAMETOOLONG = (WSABASEERR + 63),
  51. WSAEHOSTDOWN = (WSABASEERR + 64),
  52. WSAEHOSTUNREACH = (WSABASEERR + 65),
  53. WSAENOTEMPTY = (WSABASEERR + 66),
  54. WSAEPROCLIM = (WSABASEERR + 67),
  55. WSAEUSERS = (WSABASEERR + 68),
  56. WSAEDQUOT = (WSABASEERR + 69),
  57. WSAESTALE = (WSABASEERR + 70),
  58. WSAEREMOTE = (WSABASEERR + 71),
  59. /*
  60. * Extended Windows Sockets error constant definitions
  61. */
  62. WSASYSNOTREADY = (WSABASEERR + 91),
  63. WSAVERNOTSUPPORTED = (WSABASEERR + 92),
  64. WSANOTINITIALISED = (WSABASEERR + 93),
  65. WSAEDISCON = (WSABASEERR + 101),
  66. WSAENOMORE = (WSABASEERR + 102),
  67. WSAECANCELLED = (WSABASEERR + 103),
  68. WSAEINVALIDPROCTABLE = (WSABASEERR + 104),
  69. WSAEINVALIDPROVIDER = (WSABASEERR + 105),
  70. WSAEPROVIDERFAILEDINIT = (WSABASEERR + 106),
  71. WSASYSCALLFAILURE = (WSABASEERR + 107),
  72. WSASERVICE_NOT_FOUND = (WSABASEERR + 108),
  73. WSATYPE_NOT_FOUND = (WSABASEERR + 109),
  74. WSA_E_NO_MORE = (WSABASEERR + 110),
  75. WSA_E_CANCELLED = (WSABASEERR + 111),
  76. WSAEREFUSED = (WSABASEERR + 112),
  77. /*
  78. * Error return codes from gethostbyname() and gethostbyaddr()
  79. * (when using the resolver). Note that these errors are
  80. * retrieved via WSAGetLastError() and must therefore follow
  81. * the rules for avoiding clashes with error numbers from
  82. * specific implementations or language run-time systems.
  83. * For this reason the codes are based at WSABASEERR+1001.
  84. * Note also that [WSA]NO_ADDRESS is defined only for
  85. * compatibility purposes.
  86. */
  87. /* Authoritative Answer: Host not found */
  88. WSAHOST_NOT_FOUND = (WSABASEERR + 1001),
  89. /* Non-Authoritative: Host not found, or SERVERFAIL */
  90. WSATRY_AGAIN = (WSABASEERR + 1002),
  91. /* Non-recoverable errors, FORMERR, REFUSED, NOTIMP */
  92. WSANO_RECOVERY = (WSABASEERR + 1003),
  93. /* Valid name, no data record of requested type */
  94. WSANO_DATA = (WSABASEERR + 1004),
  95. /*
  96. * Define QOS related error return codes
  97. *
  98. */
  99. WSA_QOS_RECEIVERS = (WSABASEERR + 1005),
  100. /* at least one Reserve has arrived */
  101. WSA_QOS_SENDERS = (WSABASEERR + 1006),
  102. /* at least one Path has arrived */
  103. WSA_QOS_NO_SENDERS = (WSABASEERR + 1007),
  104. /* there are no senders */
  105. WSA_QOS_NO_RECEIVERS = (WSABASEERR + 1008),
  106. /* there are no receivers */
  107. WSA_QOS_REQUEST_CONFIRMED = (WSABASEERR + 1009),
  108. /* Reserve has been confirmed */
  109. WSA_QOS_ADMISSION_FAILURE = (WSABASEERR + 1010),
  110. /* error due to lack of resources */
  111. WSA_QOS_POLICY_FAILURE = (WSABASEERR + 1011),
  112. /* rejected for administrative reasons - bad credentials */
  113. WSA_QOS_BAD_STYLE = (WSABASEERR + 1012),
  114. /* unknown or conflicting style */
  115. WSA_QOS_BAD_OBJECT = (WSABASEERR + 1013),
  116. /* problem with some part of the filterspec or providerspecific
  117. * buffer in general */
  118. WSA_QOS_TRAFFIC_CTRL_ERROR = (WSABASEERR + 1014),
  119. /* problem with some part of the flowspec */
  120. WSA_QOS_GENERIC_ERROR = (WSABASEERR + 1015),
  121. }
  122. }