summaryrefslogtreecommitdiff
path: root/inode-item.c
diff options
context:
space:
mode:
authorDavid Sterba <dsterba@suse.com>2016-09-13 12:00:17 +0200
committerDavid Sterba <dsterba@suse.com>2016-10-03 11:33:15 +0200
commit890f4a61d7f4563af24617e7b2a5002cb2bf04cf (patch)
tree5396da9d1794403f8420f87c2b26c81e3e8ba5e9 /inode-item.c
parent555743075b5cc924021dd1e1a4a4697ee91441d8 (diff)
btrfs-progs: cleanup, kill trivial btrfs_key_type helper
Signed-off-by: David Sterba <dsterba@suse.com>
Diffstat (limited to 'inode-item.c')
-rw-r--r--inode-item.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/inode-item.c b/inode-item.c
index d563d4ee..913b81ad 100644
--- a/inode-item.c
+++ b/inode-item.c
@@ -128,13 +128,13 @@ int btrfs_lookup_inode(struct btrfs_trans_handle *trans, struct btrfs_root
struct btrfs_key found_key;
ret = btrfs_search_slot(trans, root, location, path, ins_len, cow);
- if (ret > 0 && btrfs_key_type(location) == BTRFS_ROOT_ITEM_KEY &&
+ if (ret > 0 && location->type == BTRFS_ROOT_ITEM_KEY &&
location->offset == (u64)-1 && path->slots[0] != 0) {
slot = path->slots[0] - 1;
leaf = path->nodes[0];
btrfs_item_key_to_cpu(leaf, &found_key, slot);
if (found_key.objectid == location->objectid &&
- btrfs_key_type(&found_key) == btrfs_key_type(location)) {
+ found_key.type == location->type) {
path->slots[0]--;
return 0;
}