mirror of
https://github.com/shadps4-emu/shadPS4.git
synced 2025-01-17 04:06:25 +00:00
Add nullptr check in scePthreadSetprio function (#1028)
This commit is contained in:
parent
b2de662d67
commit
1ec8f34a99
|
@ -1506,6 +1506,10 @@ int PS4_SYSV_ABI scePthreadGetprio(ScePthread thread, int* prio) {
|
||||||
return ORBIS_OK;
|
return ORBIS_OK;
|
||||||
}
|
}
|
||||||
int PS4_SYSV_ABI scePthreadSetprio(ScePthread thread, int prio) {
|
int PS4_SYSV_ABI scePthreadSetprio(ScePthread thread, int prio) {
|
||||||
|
if (thread == nullptr) {
|
||||||
|
LOG_ERROR(Kernel_Pthread, "scePthreadSetprio: thread is nullptr");
|
||||||
|
return ORBIS_KERNEL_ERROR_EINVAL;
|
||||||
|
}
|
||||||
thread->prio = prio;
|
thread->prio = prio;
|
||||||
return ORBIS_OK;
|
return ORBIS_OK;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue