From 1a2b2927f3970054382db6d4d6eb523620243fa1 Mon Sep 17 00:00:00 2001 From: georgemoralis Date: Thu, 5 Dec 2024 17:36:52 +0200 Subject: [PATCH] fixed some merging issues --- src/core/devices/base_device.h | 1 + src/core/libraries/kernel/file_system.cpp | 6 +++--- src/core/libraries/kernel/kernel.cpp | 5 +++-- 3 files changed, 7 insertions(+), 5 deletions(-) diff --git a/src/core/devices/base_device.h b/src/core/devices/base_device.h index 1a1e0ee6d..8b4d81613 100644 --- a/src/core/devices/base_device.h +++ b/src/core/devices/base_device.h @@ -6,6 +6,7 @@ #include "common/types.h" #include "common/va_ctx.h" #include "core/libraries/error_codes.h" +#include namespace Libraries::Kernel { struct OrbisKernelStat; diff --git a/src/core/libraries/kernel/file_system.cpp b/src/core/libraries/kernel/file_system.cpp index f07c62b31..447467cb7 100644 --- a/src/core/libraries/kernel/file_system.cpp +++ b/src/core/libraries/kernel/file_system.cpp @@ -250,7 +250,7 @@ size_t PS4_SYSV_ABI _readv(int d, const SceKernelIovec* iov, int iovcnt) { auto* h = Common::Singleton::Instance(); auto* file = h->GetFile(d); if (file == nullptr) { - return SCE_KERNEL_ERROR_EBADF; + return ORBIS_KERNEL_ERROR_EBADF; } std::scoped_lock lk{file->m_mutex}; @@ -299,7 +299,7 @@ s64 PS4_SYSV_ABI sceKernelLseek(int d, s64 offset, int whence) { auto* h = Common::Singleton::Instance(); auto* file = h->GetFile(d); if (file == nullptr) { - return SCE_KERNEL_ERROR_EBADF; + return ORBIS_KERNEL_ERROR_EBADF; } std::scoped_lock lk{file->m_mutex}; @@ -603,7 +603,7 @@ s32 PS4_SYSV_ABI sceKernelFsync(int fd) { auto* h = Common::Singleton::Instance(); auto* file = h->GetFile(fd); if (file == nullptr) { - return SCE_KERNEL_ERROR_EBADF; + return ORBIS_KERNEL_ERROR_EBADF; } if (file->type == Core::FileSys::FileType::Device) { diff --git a/src/core/libraries/kernel/kernel.cpp b/src/core/libraries/kernel/kernel.cpp index 5303a7d4d..0b4e89fc7 100644 --- a/src/core/libraries/kernel/kernel.cpp +++ b/src/core/libraries/kernel/kernel.cpp @@ -27,6 +27,7 @@ #ifdef _WIN64 #include #endif +#include namespace Libraries::Kernel { @@ -135,7 +136,7 @@ s64 PS4_SYSV_ABI ps4__write(int d, const char* buf, std::size_t nbytes) { auto* h = Common::Singleton::Instance(); auto* file = h->GetFile(d); if (file == nullptr) { - return SCE_KERNEL_ERROR_EBADF; + return ORBIS_KERNEL_ERROR_EBADF; } std::scoped_lock lk{file->m_mutex}; if (file->type == Core::FileSys::FileType::Device) { @@ -152,7 +153,7 @@ s64 PS4_SYSV_ABI ps4__read(int d, void* buf, u64 nbytes) { auto* h = Common::Singleton::Instance(); auto* file = h->GetFile(d); if (file == nullptr) { - return SCE_KERNEL_ERROR_EBADF; + return ORBIS_KERNEL_ERROR_EBADF; } std::scoped_lock lk{file->m_mutex}; if (file->type == Core::FileSys::FileType::Device) {