mirror of
https://github.com/shadps4-emu/shadPS4.git
synced 2025-07-22 10:04:39 +00:00
NetCtl: run provided callbacks
This commit is contained in:
parent
879d787dd0
commit
0627a89874
@ -96,7 +96,9 @@ int PS4_SYSV_ABI sceNetCtlUnregisterCallbackV6() {
|
|||||||
}
|
}
|
||||||
|
|
||||||
int PS4_SYSV_ABI sceNetCtlCheckCallback() {
|
int PS4_SYSV_ABI sceNetCtlCheckCallback() {
|
||||||
LOG_DEBUG(Lib_NetCtl, "(STUBBED) called");
|
LOG_DEBUG(Lib_NetCtl, "called");
|
||||||
|
|
||||||
|
netctl.CheckCallback();
|
||||||
return ORBIS_OK;
|
return ORBIS_OK;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -299,7 +301,7 @@ int PS4_SYSV_ABI sceNetCtlGetWifiType() {
|
|||||||
}
|
}
|
||||||
|
|
||||||
int PS4_SYSV_ABI sceNetCtlInit() {
|
int PS4_SYSV_ABI sceNetCtlInit() {
|
||||||
LOG_ERROR(Lib_NetCtl, "(STUBBED) called");
|
LOG_DEBUG(Lib_NetCtl, "called");
|
||||||
return ORBIS_OK;
|
return ORBIS_OK;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -312,12 +314,17 @@ int PS4_SYSV_ABI sceNetCtlRegisterCallback(OrbisNetCtlCallback func, void* arg,
|
|||||||
if (!func || !cid) {
|
if (!func || !cid) {
|
||||||
return ORBIS_NET_CTL_ERROR_INVALID_ADDR;
|
return ORBIS_NET_CTL_ERROR_INVALID_ADDR;
|
||||||
}
|
}
|
||||||
|
|
||||||
s32 result = netctl.RegisterCallback(func, arg);
|
s32 result = netctl.RegisterCallback(func, arg);
|
||||||
|
|
||||||
if (result < 0) {
|
if (result < 0) {
|
||||||
|
LOG_DEBUG(Lib_NetCtl, "failed with {:#x}", result);
|
||||||
return result;
|
return result;
|
||||||
} else {
|
} else {
|
||||||
|
LOG_DEBUG(Lib_NetCtl, "*cid = {}", result);
|
||||||
*cid = result;
|
*cid = result;
|
||||||
}
|
}
|
||||||
|
|
||||||
return ORBIS_OK;
|
return ORBIS_OK;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -387,7 +394,9 @@ int PS4_SYSV_ABI Func_D8DCB6973537A3DC() {
|
|||||||
}
|
}
|
||||||
|
|
||||||
int PS4_SYSV_ABI sceNetCtlCheckCallbackForNpToolkit() {
|
int PS4_SYSV_ABI sceNetCtlCheckCallbackForNpToolkit() {
|
||||||
LOG_DEBUG(Lib_NetCtl, "(STUBBED) called");
|
LOG_DEBUG(Lib_NetCtl, "called");
|
||||||
|
|
||||||
|
netctl.CheckNpToolkitCallback();
|
||||||
return ORBIS_OK;
|
return ORBIS_OK;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -401,10 +410,14 @@ int PS4_SYSV_ABI sceNetCtlRegisterCallbackForNpToolkit(OrbisNetCtlCallbackForNpT
|
|||||||
if (!func || !cid) {
|
if (!func || !cid) {
|
||||||
return ORBIS_NET_CTL_ERROR_INVALID_ADDR;
|
return ORBIS_NET_CTL_ERROR_INVALID_ADDR;
|
||||||
}
|
}
|
||||||
|
|
||||||
s32 result = netctl.RegisterNpToolkitCallback(func, arg);
|
s32 result = netctl.RegisterNpToolkitCallback(func, arg);
|
||||||
|
|
||||||
if (result < 0) {
|
if (result < 0) {
|
||||||
|
LOG_WARNING(Lib_NetCtl, "failed with {:#x}", result);
|
||||||
return result;
|
return result;
|
||||||
} else {
|
} else {
|
||||||
|
LOG_DEBUG(Lib_NetCtl, "*cid = {}", result);
|
||||||
*cid = result;
|
*cid = result;
|
||||||
}
|
}
|
||||||
return ORBIS_OK;
|
return ORBIS_OK;
|
||||||
|
Loading…
Reference in New Issue
Block a user