cleanup pipe handles after use

This commit is contained in:
goeiecool9999 2026-04-05 23:24:02 +02:00
parent fc7d10a483
commit 0cc843b7ea

View File

@ -344,12 +344,8 @@ void WorkaroundChildAbortHandler(int unused)
_exit(2);
}
void LinuxBreathOfTheWildWorkaround()
void PerformBOTWLinuxWorkaround(int subProcessPipes[2])
{
int subProcessPipes[2]{};
pipe(subProcessPipes);
int childID = fork();
if (childID == 0) // inside this if statement runs in child
{
@ -439,6 +435,17 @@ void LinuxBreathOfTheWildWorkaround()
}
}
void LinuxBreathOfTheWildWorkaround()
{
int subProcessPipes[2]{};
pipe(subProcessPipes);
PerformBOTWLinuxWorkaround(subProcessPipes);
close(subProcessPipes[0]);
close(subProcessPipes[1]);
}
#endif
VulkanRenderer::VulkanRenderer()