Skip to content

Commit 4469060

Browse files
committed
Switch to output() from spawn() to avoid zombies
1 parent 4c6e7c6 commit 4469060

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/lib.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1988,10 +1988,10 @@ impl Build {
19881988

19891989
// Check if gnu compiler is present
19901990
// if not, use clang
1991-
if Command::new(&gnu_compiler).spawn().is_ok() {
1991+
if Command::new(&gnu_compiler).output().is_ok() {
19921992
gnu_compiler
19931993
} else if host.contains("windows")
1994-
&& Command::new(&clang_compiler).spawn().is_err()
1994+
&& Command::new(&clang_compiler).output().is_ok()
19951995
{
19961996
clang_compiler_cmd
19971997
} else {

0 commit comments

Comments
 (0)