Added ifdef to make windows only for WSAGetError

This commit is contained in:
Matthew Parlane 2012-01-31 19:43:24 +13:00
parent 552545fa8a
commit f9979701e1
1 changed files with 4 additions and 1 deletions

View File

@ -383,12 +383,15 @@ u32 CWII_IPC_HLE_Device_net_ssl::ExecuteCommandV(u32 _Parameter, SIOCtlVBuffer C
if (returnValue == -1)
returnValue = -SSL_ERROR_WANT_READ;
if (returnValue == -5){
#ifdef _WIN32
int errorCode = WSAGetLastError();
if (errorCode == 10057){
returnValue = -SSL_ERROR_WANT_READ;
}else{
WARN_LOG(WII_IPC_NET, "/dev/net/ssl::IOCtlV request IOCTLV_NET_SSL_READ ERRORCODE= %d", WSAGetLastError());
WARN_LOG(WII_IPC_NET, "/dev/net/ssl::IOCtlV request IOCTLV_NET_SSL_READ ERRORCODE= %d", errorCode);
}
#endif
}
Memory::Write_U32(returnValue, _BufferIn);
}