You can use $sock().wsmsg that return the winsock error message but here is a basic description :
1) impossible to interpret the request because of a format error
2) internal error from the server
3) address doesn't exist
4) request type not supported
5) access denied
6+) not documented