summaryrefslogtreecommitdiff
path: root/dir-test.c
diff options
context:
space:
mode:
authorEric Sandeen <sandeen@redhat.com>2013-08-02 19:52:43 -0500
committerDavid Sterba <dsterba@suse.cz>2013-09-03 19:40:46 +0200
commit4e8c4d4ba72cba988a072246ce6de50e2e190c68 (patch)
tree4ced09fdcf5aaf89db28ce7c04554ec89adac388 /dir-test.c
parent9db49418b367ede03954d5a42c92e8dfcc10f7ad (diff)
downloadbtrfs-progs-4e8c4d4ba72cba988a072246ce6de50e2e190c68.tar.gz
btrfs-progs-4e8c4d4ba72cba988a072246ce6de50e2e190c68.tar.bz2
btrfs-progs-4e8c4d4ba72cba988a072246ce6de50e2e190c68.zip
btrfs-progs: drop unused parameter from btrfs_release_path
Port of commit b3b4aa7 to userspace. parameter tree root it's not used since commit 5f39d397dfbe140a14edecd4e73c34ce23c4f9ee ("Btrfs: Create extent_buffer interface for large blocksizes") This gets userspace a tad closer to kernelspace by removing this unused parameter that was all over the codebase... Signed-off-by: Eric Sandeen <sandeen@redhat.com> Signed-off-by: David Sterba <dsterba@suse.cz> Signed-off-by: Chris Mason <chris.mason@fusionio.com>
Diffstat (limited to 'dir-test.c')
-rw-r--r--dir-test.c20
1 files changed, 10 insertions, 10 deletions
diff --git a/dir-test.c b/dir-test.c
index c7644d68..d95219a1 100644
--- a/dir-test.c
+++ b/dir-test.c
@@ -133,11 +133,11 @@ error:
foundhash = btrfs_name_hash(found, found_len);
if (myhash != foundhash)
goto fatal_release;
- btrfs_release_path(root, &path);
+ btrfs_release_path(&path);
return 0;
}
fatal_release:
- btrfs_release_path(root, &path);
+ btrfs_release_path(&path);
fatal:
printf("failed to insert %lu ret %d\n", oid, ret);
return -1;
@@ -189,7 +189,7 @@ static int del_dir_item(struct btrfs_trans_handle *trans,
ret = btrfs_del_item(trans, root, path);
if (ret)
goto out_release;
- btrfs_release_path(root, path);
+ btrfs_release_path(path);
/* delete the inode */
btrfs_init_path(path);
@@ -199,7 +199,7 @@ static int del_dir_item(struct btrfs_trans_handle *trans,
ret = btrfs_del_item(trans, root, path);
if (ret)
goto out_release;
- btrfs_release_path(root, path);
+ btrfs_release_path(path);
if (root->fs_info->last_inode_alloc > file_objectid)
root->fs_info->last_inode_alloc = file_objectid;
@@ -210,7 +210,7 @@ static int del_dir_item(struct btrfs_trans_handle *trans,
}
return 0;
out_release:
- btrfs_release_path(root, path);
+ btrfs_release_path(path);
out:
printf("failed to delete %lu %d\n", radix_index, ret);
return -1;
@@ -239,7 +239,7 @@ static int del_one(struct btrfs_trans_handle *trans, struct btrfs_root *root,
goto out_release;
return ret;
out_release:
- btrfs_release_path(root, &path);
+ btrfs_release_path(&path);
printf("failed to delete %lu %d\n", oid, ret);
return -1;
}
@@ -266,7 +266,7 @@ static int lookup_item(struct btrfs_trans_handle *trans, struct btrfs_root
struct btrfs_dir_item);
objectid = btrfs_disk_key_objectid(&di->location);
}
- btrfs_release_path(root, &path);
+ btrfs_release_path(&path);
if (ret) {
printf("unable to find key %lu\n", oid);
return -1;
@@ -289,7 +289,7 @@ static int lookup_enoent(struct btrfs_trans_handle *trans, struct btrfs_root
btrfs_init_path(&path);
ret = btrfs_lookup_dir_item(trans, root, &path, dir_oid, buf,
strlen(buf), 0);
- btrfs_release_path(root, &path);
+ btrfs_release_path(&path);
if (!ret) {
printf("able to find key that should not exist %lu\n", oid);
return -1;
@@ -318,12 +318,12 @@ static int empty_tree(struct btrfs_trans_handle *trans, struct btrfs_root
btrfs_init_path(&path);
ret = btrfs_search_slot(trans, root, &key, &path, -1, 1);
if (ret < 0) {
- btrfs_release_path(root, &path);
+ btrfs_release_path(&path);
return ret;
}
if (ret != 0) {
if (path.slots[0] == 0) {
- btrfs_release_path(root, &path);
+ btrfs_release_path(&path);
break;
}
path.slots[0] -= 1;