xfs: Fix the situation that mount operation rejects corrupted XFS
[xfstests-dev.git] / tests / xfs / 099
index f5750be6858bc3d81250bc3261edf10fea40b386..a80644408e50ae6322362c105d2b65fd62e40bf0 100755 (executable)
@@ -66,10 +66,9 @@ __populate_check_xfs_dir "${inode}" block
 echo "+ corrupt dir"
 _scratch_xfs_db -x -c "inode ${inode}" -c 'dblock 0' -c "stack" -c "blocktrash -x 32 -y $((blksz * 8)) -z ${FUZZ_ARGS}" >> $seqres.full
 
-echo "+ mount image"
+echo "+ mount image && modify dir"
 if _try_scratch_mount >> $seqres.full 2>&1; then
 
-       echo "+ modify dir"
        rm -rf "${SCRATCH_MNT}/blockdir/00000000" 2> /dev/null && _fail "modified corrupt directory"
        mkdir "${SCRATCH_MNT}/blockdir/xxxxxxxx" 2> /dev/null && _fail "add to corrupt directory"
        umount "${SCRATCH_MNT}"