summaryrefslogtreecommitdiffstats
path: root/tests
diff options
context:
space:
mode:
authorTavian Barnes <tavianator@tavianator.com>2016-10-22 21:05:47 -0400
committerTavian Barnes <tavianator@tavianator.com>2016-10-24 11:19:24 -0400
commit3c8233869d34713860c48b1230c3ea06b8767b88 (patch)
treed2c95dd2370cfd8b1255c08c83b953c29ccd91f2 /tests
parent087b29c53e13299e195942e48ae309817f4f1d93 (diff)
downloadbfs-3c8233869d34713860c48b1230c3ea06b8767b88.tar.xz
Implement -ignore_readdir_race.
Diffstat (limited to 'tests')
-rwxr-xr-xtests/remove-sibling.sh10
1 files changed, 10 insertions, 0 deletions
diff --git a/tests/remove-sibling.sh b/tests/remove-sibling.sh
new file mode 100755
index 0000000..ddf81d7
--- /dev/null
+++ b/tests/remove-sibling.sh
@@ -0,0 +1,10 @@
+#!/bin/bash
+
+for file in "${1%/*}"/*; do
+ if [ "$file" != "$1" ]; then
+ rm "$file"
+ exit $?
+ fi
+done
+
+exit 1