btrfs-progs: convert: remove unused inode_key in copy_single_inode
authorJeff Mahoney <jeffm@suse.com>
Fri, 16 Aug 2013 14:39:27 +0000 (10:39 -0400)
committerDavid Sterba <dsterba@suse.cz>
Fri, 5 Jun 2015 20:01:28 +0000 (22:01 +0200)
Signed-off-by: Jeff Mahoney <jeffm@suse.com>
Signed-off-by: David Sterba <dsterba@suse.cz>
btrfs-convert.c

index 4754ba0ee646b29239c81ab84de24d18c195b10d..bf484844d1e93266848e343d6deeb2ecb5af6ad0 100644 (file)
@@ -1041,7 +1041,6 @@ static int copy_single_inode(struct btrfs_trans_handle *trans,
                             int datacsum, int packing, int noxattr)
 {
        int ret;
-       struct btrfs_key inode_key;
        struct btrfs_inode_item btrfs_inode;
 
        if (ext2_inode->i_links_count == 0)
@@ -1080,11 +1079,7 @@ static int copy_single_inode(struct btrfs_trans_handle *trans,
                if (ret)
                        return ret;
        }
-       inode_key.objectid = objectid;
-       inode_key.offset = 0;
-       btrfs_set_key_type(&inode_key, BTRFS_INODE_ITEM_KEY);
-       ret = btrfs_insert_inode(trans, root, objectid, &btrfs_inode);
-       return ret;
+       return btrfs_insert_inode(trans, root, objectid, &btrfs_inode);
 }
 
 static int copy_disk_extent(struct btrfs_root *root, u64 dst_bytenr,