From: Eric Biggers Date: Sat, 30 May 2015 20:47:58 +0000 (-0500) Subject: Use "EXIT" instead of "exit" in bash trap statements X-Git-Tag: v1.8.2~121 X-Git-Url: https://wimlib.net/git/?p=wimlib;a=commitdiff_plain;h=91bc75b37c64202637c2e2d2fe5b2d3005356e4d 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(). --- 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