change error strings to an enumerated array in rodata; print_error takes a file argument

This commit is contained in:
jason
2024-06-28 07:45:24 -04:00
parent f24f72c280
commit a15cbc474d
4 changed files with 142 additions and 139 deletions
+1 -1
View File
@@ -233,7 +233,7 @@ _process_start :: proc(name: string, argv: []string, attr: ^Process_Attributes)
}
if errno = linux.execveat(dir_fd, executable, &cargs[OUT], env); errno != .NONE {
print_error(_get_platform_error(errno), string(executable))
print_error(stderr, _get_platform_error(errno), string(executable))
panic("execve failed to replace process")
}
unreachable()