mirror of
https://github.com/shadps4-emu/shadPS4.git
synced 2025-04-20 19:44:46 +00:00
some rework on netctl calls
This commit is contained in:
parent
873fbc469b
commit
68e039b7ef
4 changed files with 14 additions and 3 deletions
|
@ -26,3 +26,11 @@ constexpr int ORBIS_NET_CTL_STATE_IPOBTAINED = 3;
|
|||
constexpr int ORBIS_NET_CTL_EVENT_TYPE_DISCONNECTED = 1;
|
||||
constexpr int ORBIS_SCE_NET_CTL_EVENT_TYPE_DISCONNECT_REQ_FINISHED = 2;
|
||||
constexpr int ORBIS_NET_CTL_EVENT_TYPE_IPOBTAINED = 3;
|
||||
|
||||
// get info codes
|
||||
// device
|
||||
constexpr int ORBIS_NET_CTL_DEVICE_WIRED = 0;
|
||||
constexpr int ORBIS_NET_CTL_DEVICE_WIRELESS = 1;
|
||||
// link
|
||||
constexpr int ORBIS_NET_CTL_LINK_DISCONNECTED = 0;
|
||||
constexpr int ORBIS_NET_CTL_LINK_CONNECTED = 1;
|
||||
|
|
0
src/core/libraries/network/net_obj.cpp
Normal file
0
src/core/libraries/network/net_obj.cpp
Normal file
0
src/core/libraries/network/net_obj.h
Normal file
0
src/core/libraries/network/net_obj.h
Normal file
|
@ -149,10 +149,10 @@ int PS4_SYSV_ABI sceNetCtlGetIfStat() {
|
|||
int PS4_SYSV_ABI sceNetCtlGetInfo(int code, OrbisNetCtlInfo* info) {
|
||||
switch (code) {
|
||||
case ORBIS_NET_CTL_INFO_DEVICE:
|
||||
info->device = 0;
|
||||
info->device = ORBIS_NET_CTL_DEVICE_WIRED;
|
||||
break;
|
||||
case ORBIS_NET_CTL_INFO_LINK:
|
||||
info->link = 0; // disconnected
|
||||
info->link = ORBIS_NET_CTL_LINK_DISCONNECTED;
|
||||
break;
|
||||
default:
|
||||
LOG_ERROR(Lib_NetCtl, "{} unsupported code", code);
|
||||
|
@ -187,7 +187,10 @@ int PS4_SYSV_ABI sceNetCtlGetNetEvConfigInfoIpcInt() {
|
|||
}
|
||||
|
||||
int PS4_SYSV_ABI sceNetCtlGetResult(int eventType, int* errorCode) {
|
||||
LOG_ERROR(Lib_NetCtl, "(STUBBED) called eventType = {} ", eventType);
|
||||
if (!errorCode) {
|
||||
return ORBIS_NET_CTL_ERROR_INVALID_ADDR;
|
||||
}
|
||||
LOG_DEBUG(Lib_NetCtl, "(STUBBED) called eventType = {} ", eventType);
|
||||
*errorCode = 0;
|
||||
return ORBIS_OK;
|
||||
}
|
||||
|
|
Loading…
Add table
Reference in a new issue