diff mbox series

[7/8] btrfs/291: remove image file after teardown

Message ID 096e64b057469f65b6f2e36f5d96680235889273.1709664047.git.dsterba@suse.com (mailing list archive)
State New, archived
Headers show
Series Btrfs fstests fixups | expand

Commit Message

David Sterba March 5, 2024, 6:52 p.m. UTC
From: Josef Bacik <josef@toxicpanda.com>

LVM doesn't like it when you remove the file out from underneath the
backing device.

Signed-off-by: Josef Bacik <josef@toxicpanda.com>
---
 tests/btrfs/291 | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
diff mbox series

Patch

diff --git a/tests/btrfs/291 b/tests/btrfs/291
index c5947133239940..bfffb845fea740 100755
--- a/tests/btrfs/291
+++ b/tests/btrfs/291
@@ -20,9 +20,9 @@  _cleanup()
 {
 	cd /
 	_log_writes_cleanup &> /dev/null
-	rm -f $img
 	$LVM_PROG vgremove -f -y $vgname >>$seqres.full 2>&1
 	losetup -d $loop_dev >>$seqres.full 2>&1
+	rm -f $img
 	_restore_fsverity_signatures
 }