diff options
Diffstat (limited to 'util/wrap.pl.in')
-rw-r--r-- | util/wrap.pl.in | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/util/wrap.pl.in b/util/wrap.pl.in index b13c34d851..de4692f319 100644 --- a/util/wrap.pl.in +++ b/util/wrap.pl.in @@ -68,7 +68,10 @@ my $waitcode = system @cmd; die "wrap.pl: Failed to execute '", join(' ', @cmd), "': $!\n" if $waitcode == -1; -# When the subprocess aborted on a signal, mimic what Unix shells do, by +# When the subprocess aborted on a signal, we simply raise the same signal. +kill ($? & 255) => $$ if ($? & 255) != 0; + +# If that didn't stop this script, mimic what Unix shells do, by # converting the signal code to an exit code by setting the high bit. # This only happens on Unix flavored operating systems, the others don't # have this sort of signaling to date, and simply leave the low byte zero. |