Skip to content

Commit

Permalink
Switch to output() from spawn() to avoid zombies
Browse files Browse the repository at this point in the history
  • Loading branch information
alexcrichton committed Apr 22, 2020
1 parent 4c6e7c6 commit 4469060
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -1988,10 +1988,10 @@ impl Build {

// Check if gnu compiler is present
// if not, use clang
if Command::new(&gnu_compiler).spawn().is_ok() {
if Command::new(&gnu_compiler).output().is_ok() {
gnu_compiler
} else if host.contains("windows")
&& Command::new(&clang_compiler).spawn().is_err()
&& Command::new(&clang_compiler).output().is_ok()
{
clang_compiler_cmd
} else {
Expand Down

0 comments on commit 4469060

Please sign in to comment.