diff --git a/Source/Core/Core/Src/IPC_HLE/WII_IPC_HLE_Device_net.cpp b/Source/Core/Core/Src/IPC_HLE/WII_IPC_HLE_Device_net.cpp index 734805cd6b..a676b53ccb 100644 --- a/Source/Core/Core/Src/IPC_HLE/WII_IPC_HLE_Device_net.cpp +++ b/Source/Core/Core/Src/IPC_HLE/WII_IPC_HLE_Device_net.cpp @@ -195,7 +195,7 @@ CWII_IPC_HLE_Device_net_ncd_manage::CWII_IPC_HLE_Device_net_ncd_manage(u32 _Devi { // store network configuration const std::string filename(File::GetUserPath(D_WIIUSER_IDX) + "shared2/sys/net/02/config.dat"); - + File::IOFile file(filename, "rb"); if (!file.ReadBytes(&m_Ifconfig, 1)) { @@ -481,6 +481,8 @@ static int getNetErrorCode(int ret, std::string caller) return -1; case 10054: return -15; + case 10056: + return -30; case 10035: return -26; case 6: @@ -545,8 +547,8 @@ static int inet_pton(const char *src, unsigned char *dst) u32 CWII_IPC_HLE_Device_net_ip_top::ExecuteCommand(u32 _Command, - u32 _BufferIn, u32 BufferInSize, - u32 _BufferOut, u32 BufferOutSize) + u32 _BufferIn, u32 BufferInSize, + u32 _BufferOut, u32 BufferOutSize) { switch (_Command) { @@ -605,13 +607,13 @@ u32 CWII_IPC_HLE_Device_net_ip_top::ExecuteCommand(u32 _Command, u32 sock = Memory::Read_U32(_BufferIn); INFO_LOG(WII_IPC_NET, "/dev/net/ip/top::IOCtl request IOCTL_SO_CLOSE (%08x)", sock); - #ifdef _WIN32 +#ifdef _WIN32 u32 ret = closesocket(sock); return getNetErrorCode(ret, "IOCTL_SO_CLOSE"); - #else +#else return close(sock); - #endif +#endif break; } @@ -682,7 +684,7 @@ u32 CWII_IPC_HLE_Device_net_ip_top::ExecuteCommand(u32 _Command, u32 optname = Memory::Read_U32(_BufferOut + 8); - + INFO_LOG(WII_IPC_NET,"/dev/net/ip/top::IOCtl request IOCTL_SO_GETSOCKOPT(%08x, %08x, %08x)" "BufferIn: (%08x, %i), BufferOut: (%08x, %i)", sock, level, optname, @@ -696,7 +698,7 @@ u32 CWII_IPC_HLE_Device_net_ip_top::ExecuteCommand(u32 _Command, //for(int i=0; i