changeset 64:547df6917df9

Without an exit in the trap, the remainig commands still get executed.
author Gerhard Siegesmund <gerhard.siegesmund@btd.de>
date Mon, 01 Jun 2015 14:15:04 +0200
parents 9e768b83d701
children 3ae6964078ab
files plat/unix/update_tags.sh
diffstat 1 files changed, 1 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/plat/unix/update_tags.sh	Sat May 16 21:51:17 2015 -0700
+++ b/plat/unix/update_tags.sh	Mon Jun 01 14:15:04 2015 +0200
@@ -67,7 +67,7 @@
 echo $$ > "$TAGS_FILE.lock"
 
 # Remove lock and temp file if script is stopped unexpectedly.
-trap "rm -f \"$TAGS_FILE.lock\" \"$TAGS_FILE.temp\"" 0 3 4 15
+trap "errorcode=$?; rm -f \"$TAGS_FILE.lock\" \"$TAGS_FILE.temp\"; exit $errorcode" INT TERM EXIT
 
 if [ -f "$TAGS_FILE" ]; then
     if [ "$UPDATED_SOURCE" != "" ]; then