From 91bc75b37c64202637c2e2d2fe5b2d3005356e4d Mon Sep 17 00:00:00 2001 From: Eric Biggers Date: Sat, 30 May 2015 15:47:58 -0500 Subject: [PATCH] Use "EXIT" instead of "exit" in bash trap statements The lower case version does not work in a Turkish locale. The upper case version is what the bash docs actually mention and is what bash actually checks against using strcasecmp(). --- programs/mkwinpeimg.in | 2 +- tests/test-imagex-update_and_extract | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/programs/mkwinpeimg.in b/programs/mkwinpeimg.in index ea0396eb..f95e8e96 100755 --- a/programs/mkwinpeimg.in +++ b/programs/mkwinpeimg.in @@ -528,7 +528,7 @@ if [ -n "$start_script" -o -n "$overlay" -o -n "$remove_setup" ]; then modify_wim=yes fi check_needed_programs -trap cleanup exit +trap cleanup EXIT if [ $make != wim ]; then mkdir -p "$tmp_dir"/{boot,sources} diff --git a/tests/test-imagex-update_and_extract b/tests/test-imagex-update_and_extract index 745c98f6..f7b8ce2a 100755 --- a/tests/test-imagex-update_and_extract +++ b/tests/test-imagex-update_and_extract @@ -24,7 +24,7 @@ fail() { msg "TEST FAILED (See above)" } -trap fail exit +trap fail EXIT prepare_empty_wim() { rm -rf in.dir @@ -285,7 +285,7 @@ WIMLIB_IMAGEX_IGNORE_CASE=1 wimextract test.wim 1 @pathlist --dest-dir=out.dir - echo "**********************************************************" echo " wimupdate/extract tests passed " echo "**********************************************************" -trap exit +trap EXIT cd .. default_cleanup -- 2.43.0