Open dir, small fixes

This commit is contained in:
Krzosa Karol
2025-12-27 21:37:41 +01:00
parent 28d8348b89
commit 1011c63494
5 changed files with 24 additions and 13 deletions

View File

@@ -293,11 +293,8 @@ API Process SpawnProcess(String command_line, String working_dir, String write_s
const int PIPE_WRITE = 1;
bool error = false;
char *buffer = AllocArray(scratch, char, 4096);
working_dir = Copy(scratch, working_dir);
chdir(working_dir.data);
getcwd(buffer, 4096);
defer { chdir(buffer); };
Process process = {};
UnixProcess *plat = (UnixProcess *)&process.platform;