From ef00e4264c6d113e4ba2d377520ff61d5775be39 Mon Sep 17 00:00:00 2001 From: james harvey Date: Thu, 7 Jun 2018 03:20:02 -0400 Subject: [PATCH] btrfs-progs: map-logical: Use btrfs_next_extent_item btrfs_next_extent_item() looks for BTRFS_EXTENT_ITEM_KEY and BTRFS_METADATA_KEY, which are the types we're looking for. Signed-off-by: James Harvey Reviewed-by: Su Yue Signed-off-by: David Sterba --- btrfs-map-logical.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/btrfs-map-logical.c b/btrfs-map-logical.c index 4508f365..cad4afc3 100644 --- a/btrfs-map-logical.c +++ b/btrfs-map-logical.c @@ -75,7 +75,8 @@ again: ret = btrfs_previous_extent_item(fs_info->extent_root, path, 0); else - ret = btrfs_next_item(fs_info->extent_root, path); + ret = btrfs_next_extent_item(fs_info->extent_root, + path, 0); if (ret) goto out; goto again;