improved file not found return in sceKernelOpen

This commit is contained in:
georgemoralis 2024-07-04 11:38:23 +03:00
parent bdcadf63d2
commit 8d17f87a08
1 changed files with 5 additions and 1 deletions

View File

@ -90,7 +90,11 @@ int PS4_SYSV_ABI sceKernelOpen(const char* path, int flags, u16 mode) {
}
if (!file->f.IsOpen()) {
h->DeleteHandle(handle);
return SCE_KERNEL_ERROR_EACCES;
if (create) {
return ORBIS_KERNEL_ERROR_EACCES;
} else {
return ORBIS_KERNEL_ERROR_ENOENT;
}
}
}
file->is_opened = true;