aboutsummaryrefslogtreecommitdiffstats
path: root/fs/btrfs/root-tree.c
diff options
context:
space:
mode:
Diffstat (limited to 'fs/btrfs/root-tree.c')
-rw-r--r--fs/btrfs/root-tree.c6
1 files changed, 5 insertions, 1 deletions
diff --git a/fs/btrfs/root-tree.c b/fs/btrfs/root-tree.c
index 3bcfe5a7c330..ebe45443de06 100644
--- a/fs/btrfs/root-tree.c
+++ b/fs/btrfs/root-tree.c
@@ -338,7 +338,10 @@ again:
338 *sequence = btrfs_root_ref_sequence(leaf, ref); 338 *sequence = btrfs_root_ref_sequence(leaf, ref);
339 339
340 ret = btrfs_del_item(trans, tree_root, path); 340 ret = btrfs_del_item(trans, tree_root, path);
341 BUG_ON(ret); 341 if (ret) {
342 err = ret;
343 goto out;
344 }
342 } else 345 } else
343 err = -ENOENT; 346 err = -ENOENT;
344 347
@@ -350,6 +353,7 @@ again:
350 goto again; 353 goto again;
351 } 354 }
352 355
356out:
353 btrfs_free_path(path); 357 btrfs_free_path(path);
354 return err; 358 return err;
355} 359}