Network: Log internal errors
This commit is contained in:
parent
652ecd2404
commit
28c6bd7af7
|
|
@ -952,6 +952,11 @@ namespace Nz
|
||||||
case EFAULT:
|
case EFAULT:
|
||||||
case ENOTSOCK:
|
case ENOTSOCK:
|
||||||
case EPROTOTYPE:
|
case EPROTOTYPE:
|
||||||
|
// Those are not errors and should have been handled
|
||||||
|
case EALREADY:
|
||||||
|
case EISCONN:
|
||||||
|
case EWOULDBLOCK:
|
||||||
|
NazaraWarning("Internal error occurred: " + Error::GetLastSystemError(error) + " (" + String::Number(error) + ')');
|
||||||
return SocketError_Internal;
|
return SocketError_Internal;
|
||||||
|
|
||||||
case EADDRNOTAVAIL:
|
case EADDRNOTAVAIL:
|
||||||
|
|
@ -965,12 +970,6 @@ namespace Nz
|
||||||
case ESOCKTNOSUPPORT:
|
case ESOCKTNOSUPPORT:
|
||||||
return SocketError_NotSupported;
|
return SocketError_NotSupported;
|
||||||
|
|
||||||
// Those are not errors and should have been handled before the call
|
|
||||||
case EALREADY:
|
|
||||||
case EISCONN:
|
|
||||||
case EWOULDBLOCK:
|
|
||||||
return SocketError_Internal;
|
|
||||||
|
|
||||||
case ECONNREFUSED:
|
case ECONNREFUSED:
|
||||||
return SocketError_ConnectionRefused;
|
return SocketError_ConnectionRefused;
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -951,6 +951,11 @@ namespace Nz
|
||||||
case WSAENOTSOCK:
|
case WSAENOTSOCK:
|
||||||
case WSAEPROTOTYPE:
|
case WSAEPROTOTYPE:
|
||||||
case WSA_INVALID_HANDLE:
|
case WSA_INVALID_HANDLE:
|
||||||
|
// Those are not errors and should have been handled
|
||||||
|
case WSAEALREADY:
|
||||||
|
case WSAEISCONN:
|
||||||
|
case WSAEWOULDBLOCK:
|
||||||
|
NazaraWarning("Internal error occurred: " + Error::GetLastSystemError(error) + " (" + String::Number(error) + ')');
|
||||||
return SocketError_Internal;
|
return SocketError_Internal;
|
||||||
|
|
||||||
case WSAEADDRNOTAVAIL:
|
case WSAEADDRNOTAVAIL:
|
||||||
|
|
@ -964,12 +969,6 @@ namespace Nz
|
||||||
case WSAESOCKTNOSUPPORT:
|
case WSAESOCKTNOSUPPORT:
|
||||||
return SocketError_NotSupported;
|
return SocketError_NotSupported;
|
||||||
|
|
||||||
// Those are not errors and should have been handled before the call
|
|
||||||
case WSAEALREADY:
|
|
||||||
case WSAEISCONN:
|
|
||||||
case WSAEWOULDBLOCK:
|
|
||||||
return SocketError_Internal;
|
|
||||||
|
|
||||||
case WSAECONNREFUSED:
|
case WSAECONNREFUSED:
|
||||||
return SocketError_ConnectionRefused;
|
return SocketError_ConnectionRefused;
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue