aboutsummaryrefslogtreecommitdiff
path: root/tools/test
diff options
context:
space:
mode:
authorPeter Holm <pho@FreeBSD.org>2022-02-22 11:07:45 +0000
committerPeter Holm <pho@FreeBSD.org>2022-02-22 11:07:45 +0000
commit14086729650b101c43424004fa754eb7f7db8e89 (patch)
tree65770f11a98916bde19a46675b9a307ac908941d /tools/test
parentadbb32d3e6b3a595e096f14422d0146967927305 (diff)
downloadsrc-14086729650b101c43424004fa754eb7f7db8e89.tar.gz
src-14086729650b101c43424004fa754eb7f7db8e89.zip
stress2: Added cleanup on error
Diffstat (limited to 'tools/test')
-rwxr-xr-xtools/test/stress2/misc/sendfile22.sh2
1 files changed, 2 insertions, 0 deletions
diff --git a/tools/test/stress2/misc/sendfile22.sh b/tools/test/stress2/misc/sendfile22.sh
index ea3a564e1561..73737fb3e352 100755
--- a/tools/test/stress2/misc/sendfile22.sh
+++ b/tools/test/stress2/misc/sendfile22.sh
@@ -63,6 +63,8 @@ while [ $((` date +%s` - start)) -lt 180 ]; do
umount $mntpoint 2>/dev/null # busy umount
$dir/sendfile22
s=$?
+ [ $s -ne 0 ] &&
+ pkill sendfile22
cmp -s input output || break
[ `stat -f '%z' input` -ne ` stat -f '%z' output` ] && break
n=$((n + 1))