diff options
author | Dmitry V. Levin <ldv@altlinux.org> | 2010-01-30 22:21:19 +0300 |
---|---|---|
committer | Ralf Wildenhues <Ralf.Wildenhues@gmx.de> | 2010-02-06 20:46:51 +0100 |
commit | dbfabdfc6521979678367ba9df3876fa2300da59 (patch) | |
tree | f79a6b4d6f38b80d658ea2ca8e2a4536089d6fa0 /lib/Automake/tests | |
parent | 1fd9d3935543368dbcb1481f52375e8543df0841 (diff) | |
download | automake-dbfabdfc6521979678367ba9df3876fa2300da59.tar.gz |
Fix exit status of signal handlers in shell scripts.
The value of `$?' on entrance to signal handlers in shell scripts
cannot be relied upon, so set the exit code explicitly to
128 + SIG<SIGNAL>.
* lib/am/check.am (am__check_pre): Use `exit 143' in signal handler.
* lib/elisp-comp: Likewise.
* lib/install-sh: Likewise.
* lib/ylwrap: Likewise. Also, fix script to trap signal 13, not 3.
* NEWS, THANKS: Update.
Bug report, analysis, and initial patch by Dmitry V. Levin.
Signed-off-by: Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
Diffstat (limited to 'lib/Automake/tests')
-rw-r--r-- | lib/Automake/tests/Makefile.in | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/lib/Automake/tests/Makefile.in b/lib/Automake/tests/Makefile.in index 5979b977c..1401eb9fe 100644 --- a/lib/Automake/tests/Makefile.in +++ b/lib/Automake/tests/Makefile.in @@ -129,8 +129,9 @@ $(am__sh_e_setup); \ $(am__vpath_adj_setup) $(am__vpath_adj) \ srcdir=$(srcdir); export srcdir; \ rm -f $@-t; \ -trap 'st=$$?; rm -f '\''$(abs_builddir)/$@-t'\''; (exit $$st); exit $$st' \ - 1 2 13 15; \ +am__trap='rm -f '\''$(abs_builddir)/$@-t'\''; (exit $$st); exit $$st'; \ +trap "st=129; $$am__trap" 1; trap "st=130; $$am__trap" 2; \ +trap "st=141; $$am__trap" 13; trap "st=143; $$am__trap" 15; \ am__odir=`echo "./$@" | sed 's|/[^/]*$$||'`; \ test "x$$am__odir" = x. || $(MKDIR_P) "$$am__odir" || exit $$?; \ if test -f "./$$f"; then dir=./; \ |