mirror of
https://github.com/golang/go
synced 2024-11-24 08:10:09 -07:00
handle compiler crash better:
need to use exec to avoid seeing shell output about the crash. R=iant DELTA=2 (1 added, 0 deleted, 1 changed) OCL=35542 CL=35560
This commit is contained in:
parent
c736b6579f
commit
7b5da358ca
@ -30,7 +30,7 @@ close(SRC);
|
||||
|
||||
# Run command
|
||||
$cmd = join(' ', @ARGV);
|
||||
open(CMD, "$cmd </dev/null 2>&1 |") || die "BUG: errchk: run $cmd: $!";
|
||||
open(CMD, "exec $cmd </dev/null 2>&1 |") || die "BUG: errchk: run $cmd: $!";
|
||||
@out = grep { !/^ / } <CMD>;
|
||||
close CMD;
|
||||
|
||||
@ -42,6 +42,7 @@ if($? == 0) {
|
||||
|
||||
if(!WIFEXITED($?)) {
|
||||
print STDERR "BUG: errchk: compiler crashed\n";
|
||||
print STDERR @out, "\n";
|
||||
exit 0;
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user