mirror of
https://github.com/Ed94/Odin.git
synced 2026-08-06 15:48:51 +00:00
Merge pull request #5825 from KamWithK/master
Linux executable path bug fix
This commit is contained in:
@@ -427,7 +427,8 @@ _process_start :: proc(desc: Process_Desc) -> (process: Process, err: Error) {
|
|||||||
strings.write_string(&exe_builder, executable_name)
|
strings.write_string(&exe_builder, executable_name)
|
||||||
|
|
||||||
exe_path = strings.to_cstring(&exe_builder) or_return
|
exe_path = strings.to_cstring(&exe_builder) or_return
|
||||||
if linux.access(exe_path, linux.X_OK) == .NONE {
|
stat := linux.Stat{}
|
||||||
|
if linux.stat(exe_path, &stat) == .NONE && .IFREG in stat.mode && .IXUSR in stat.mode {
|
||||||
found = true
|
found = true
|
||||||
break
|
break
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user