LinuxSyscalls: Track MappedResources only for regular files that are executable

This commit is contained in:
Tony Wasserka committed 2025-10-20 18:00:25 +02:00
1 parent 6c77bc12c1
commit 02c00a87dd
1 file changed
+2 -1
@@ -394,7 +394,8 @@ std::optional<SyscallHandler::LateApplyExtendedVolatileMetadata> SyscallHandler:
Resource->Iterator = Iter;
}
if (PathLength != -1) {
// Only handle FDs that are backed by regular files that are executable
if (PathLength != -1 && S_ISREG(buf.st_mode) && (buf.st_mode & S_IXUSR)) {
if (Inserted) {
Resource->MappedFile = fextl::make_unique<FEXCore::ExecutableFileInfo>();
Resource->MappedFile->Filename = fextl::string(Tmp, PathLength);