Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit d618c91

Browse files
committed
Added table of WSA error codes.
1 parent 1ed7036 commit d618c91

1 file changed

Lines changed: 19 additions & 0 deletions

File tree

Lib/plat-win/socket.py

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -131,3 +131,22 @@ def readlines(self):
131131
if not line: break
132132
list.append(line)
133133
return list
134+
135+
136+
# WSA error codes
137+
errorTab = {}
138+
errorTab[10004] = "The operation was interrupted."
139+
errorTab[10009] = "A bad file handle was passed."
140+
errorTab[10013] = "Permission denied."
141+
errorTab[10014] = "A fault occurred on the network??" # WSAEFAULT
142+
errorTab[10022] = "An invalid operation was attempted."
143+
errorTab[10035] = "The socket operation would block"
144+
errorTab[10036] = "A blocking operation is already in progress."
145+
errorTab[10048] = "The network address is in use."
146+
errorTab[10054] = "The connection has been reset."
147+
errorTab[10058] = "The network has been shut down."
148+
errorTab[10060] = "The operation timed out."
149+
errorTab[10061] = "Connection refused."
150+
errorTab[10063] = "The name is too long."
151+
errorTab[10064] = "The host is down."
152+
errorTab[10065] = "The host is unreachable."

0 commit comments

Comments
 (0)