Skip to content

Instantly share code, notes, and snippets.

@Sonicadvance1
Sonicadvance1 / getcwd_print.diff
Created June 2, 2024 12:38
getcwd_print.diff
diff --git a/Source/Tools/LinuxEmulation/LinuxSyscalls/Syscalls/Passthrough.cpp b/Source/Tools/LinuxEmulation/LinuxSyscalls/Syscalls/Passthrough.cpp
index 742b6dd61..e42706469 100644
--- a/Source/Tools/LinuxEmulation/LinuxSyscalls/Syscalls/Passthrough.cpp
+++ b/Source/Tools/LinuxEmulation/LinuxSyscalls/Syscalls/Passthrough.cpp
@@ -210,7 +210,16 @@ uint64_t SyscallPassthrough7(FEXCore::Core::CpuStateFrame* Frame, uint64_t arg1,
SYSCALL_ERRNO();
}
#endif
+uint64_t SyscallPassthrough_getcwd(FEXCore::Core::CpuStateFrame* Frame, char* Output, uint64_t Size) {
+ uint64_t Result = ::syscall(SYSCALL_DEF(getcwd), Output, Size);