From e657c59cf245f6e36b50aa1f7bb3cd45215c09bc Mon Sep 17 00:00:00 2001 From: deadcafe Date: Sat, 10 Oct 2026 01:42:41 +0530 Subject: [PATCH] playTests: use ln -sf for the xz/lzma symlinks The xz block creates ./xz, ./unxz, ./lzma and ./unlzma with `ln -s` and only removes them once the block has passed. The script runs under `set -e`, so a run that fails or is interrupted inside the block leaves the links in tests/, and every later run then aborts with "ln: ./xz: File exists". `make clean` does not remove them. Use `ln -sf`, as the script already does for the zstdcat and zcat links. fix #4431 --- tests/playTests.sh | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/tests/playTests.sh b/tests/playTests.sh index 44bc82b5610..883425728b4 100755 --- a/tests/playTests.sh +++ b/tests/playTests.sh @@ -1388,10 +1388,10 @@ if [ $LZMAMODE -eq 1 ]; then zstd -d -f -v tmp.lzma rm -f tmp* println "Creating symlinks" - ln -s "$ZSTD_BIN" ./xz - ln -s "$ZSTD_BIN" ./unxz - ln -s "$ZSTD_BIN" ./lzma - ln -s "$ZSTD_BIN" ./unlzma + ln -sf "$ZSTD_BIN" ./xz + ln -sf "$ZSTD_BIN" ./unxz + ln -sf "$ZSTD_BIN" ./lzma + ln -sf "$ZSTD_BIN" ./unlzma println "Testing xz and lzma symlinks" datagen > tmp ./xz tmp