Skip to content

Commit

Permalink
Haiku : execve not allowed if other pthreads have already been created
Browse files Browse the repository at this point in the history
  • Loading branch information
Sylvain78 committed Sep 24, 2024
1 parent abc1395 commit 390a5bf
Showing 1 changed file with 1 addition and 3 deletions.
4 changes: 1 addition & 3 deletions otherlibs/stdune/src/proc.ml
Original file line number Diff line number Diff line change
Expand Up @@ -11,9 +11,7 @@ let restore_cwd_and_execve prog argv ~env =
(* run at_exit before changing the working directory *)
Stdlib.do_at_exit ();
Sys.chdir (Path.External.to_string Path.External.initial_cwd);
let os_haiku = Sys.os_type == "BeOS" || (try ignore(Sys.getenv "BE_HOST_CPU");true with Not_found -> false)
in
if Sys.win32 || os_haiku
if Sys.win32 || Platform.OS.value == Platform.OS.Haiku
then (
let pid = Unix.create_process_env prog argv env Unix.stdin Unix.stdout Unix.stderr in
match snd (Unix.waitpid [] pid) with
Expand Down

0 comments on commit 390a5bf

Please sign in to comment.