projects
/
GitHub
/
moto-9609
/
android_kernel_motorola_exynos9610.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
b8399de
)
Btrfs: fixup return code for btrfs_del_orphan_item
author
Josef Bacik
<josef@redhat.com>
Wed, 8 Dec 2010 17:22:34 +0000
(12:22 -0500)
committer
Josef Bacik
<josef@redhat.com>
Thu, 9 Dec 2010 18:57:15 +0000
(13:57 -0500)
If the orphan item doesn't exist, we return 1, which doesn't make any sense to
the callers. Instead return -ENOENT if we didn't find the item. Thanks,
Signed-off-by: Josef Bacik <josef@redhat.com>
fs/btrfs/orphan.c
patch
|
blob
|
blame
|
history
diff --git
a/fs/btrfs/orphan.c
b/fs/btrfs/orphan.c
index 79cba5fbc28ef8061e2d599110a3a525216a7bfd..f8be250963a09a283b8ec4ab04bcb1c3a962427e 100644
(file)
--- a/
fs/btrfs/orphan.c
+++ b/
fs/btrfs/orphan.c
@@
-56,8
+56,12
@@
int btrfs_del_orphan_item(struct btrfs_trans_handle *trans,
return -ENOMEM;
ret = btrfs_search_slot(trans, root, &key, path, -1, 1);
- if (ret)
+ if (ret
< 0
)
goto out;
+ if (ret) {
+ ret = -ENOENT;
+ goto out;
+ }
ret = btrfs_del_item(trans, root, path);