From b3f15dfe2ea6738fd0585df5ac432e78a4191bd4 Mon Sep 17 00:00:00 2001 From: georgemoralis Date: Fri, 28 Jun 2024 23:19:33 +0300 Subject: [PATCH] fixed posix_open return code --- src/core/libraries/kernel/file_system.cpp | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/core/libraries/kernel/file_system.cpp b/src/core/libraries/kernel/file_system.cpp index f0556df8..6fe57406 100644 --- a/src/core/libraries/kernel/file_system.cpp +++ b/src/core/libraries/kernel/file_system.cpp @@ -100,7 +100,9 @@ int PS4_SYSV_ABI posix_open(const char* path, int flags, /* SceKernelMode*/ u16 LOG_INFO(Kernel_Fs, "posix open redirect to sceKernelOpen"); int result = sceKernelOpen(path, flags, mode); // Posix calls different only for their return values - ASSERT(result >= 0); + if (result < 0) { + return -1; + } return result; }