diff options
author | Junio C Hamano <gitster@pobox.com> | 2022-07-27 13:00:31 -0700 |
---|---|---|
committer | Junio C Hamano <gitster@pobox.com> | 2022-07-27 13:00:31 -0700 |
commit | 1d7106bae3ded3887affc83d7af9697a42269cea (patch) | |
tree | 21af73b0cb8810c1a548837a747e90121107a942 /t/test-lib.sh | |
parent | 54ec7b817d15d4e7a24935286a9f8382ce216651 (diff) | |
parent | eb1cd60290d3898ef3c3293a11400f9fff9376cd (diff) | |
download | git-1d7106bae3ded3887affc83d7af9697a42269cea.tar.gz |
Merge branch 'ab/test-quoting-fix' into maint
Fixes for tests when the source directory has unusual characters in
its path, e.g. whitespaces, double-quotes, etc.
source: <cover-v2-0.3-00000000000-20220630T101646Z-avarab@gmail.com>
* ab/test-quoting-fix:
config tests: fix harmless but broken "rm -r" cleanup
test-lib.sh: fix prepend_var() quoting issue
tests: add missing double quotes to included library paths
Diffstat (limited to 't/test-lib.sh')
-rw-r--r-- | t/test-lib.sh | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/t/test-lib.sh b/t/test-lib.sh index 55857af601..8cabb4d10f 100644 --- a/t/test-lib.sh +++ b/t/test-lib.sh @@ -57,14 +57,14 @@ fi # # prepend_var VAR : VALUE prepend_var () { - eval "$1=$3\${$1:+${3:+$2}\$$1}" + eval "$1=\"$3\${$1:+${3:+$2}\$$1}\"" } # If [AL]SAN is in effect we want to abort so that we notice # problems. The GIT_SAN_OPTIONS variable can be used to set common # defaults shared between [AL]SAN_OPTIONS. prepend_var GIT_SAN_OPTIONS : abort_on_error=1 -prepend_var GIT_SAN_OPTIONS : strip_path_prefix=\"$GIT_BUILD_DIR/\" +prepend_var GIT_SAN_OPTIONS : strip_path_prefix="$GIT_BUILD_DIR/" # If we were built with ASAN, it may complain about leaks # of program-lifetime variables. Disable it by default to lower |