summaryrefslogtreecommitdiff
path: root/fs/xfs/libxfs/xfs_exchmaps.c
diff options
context:
space:
mode:
Diffstat (limited to 'fs/xfs/libxfs/xfs_exchmaps.c')
-rw-r--r--fs/xfs/libxfs/xfs_exchmaps.c9
1 files changed, 2 insertions, 7 deletions
diff --git a/fs/xfs/libxfs/xfs_exchmaps.c b/fs/xfs/libxfs/xfs_exchmaps.c
index 44ab6a9235c0..2021396651de 100644
--- a/fs/xfs/libxfs/xfs_exchmaps.c
+++ b/fs/xfs/libxfs/xfs_exchmaps.c
@@ -465,17 +465,12 @@ xfs_exchmaps_dir_to_sf(
};
struct xfs_dir2_sf_hdr sfh;
struct xfs_buf *bp;
- bool isblock;
int size;
- int error;
+ int error = 0;
- error = xfs_dir2_isblock(&args, &isblock);
- if (error)
+ if (xfs_dir2_format(&args, &error) != XFS_DIR2_FMT_BLOCK)
return error;
- if (!isblock)
- return 0;
-
error = xfs_dir3_block_read(tp, xmi->xmi_ip2, xmi->xmi_ip2->i_ino, &bp);
if (error)
return error;