]> git.proxmox.com Git - mirror_ubuntu-disco-kernel.git/commitdiff
Btrfs: cleanup to remove reduplicate code in transaction.c
authorWang Shilong <wangsl-fnst@cn.fujitsu.com>
Sun, 14 Apr 2013 14:08:49 +0000 (14:08 +0000)
committerJosef Bacik <jbacik@fusionio.com>
Mon, 6 May 2013 19:54:49 +0000 (15:54 -0400)
Signed-off-by: Wang Shilong <wangsl-fnst@cn.fujitsu.com>
Signed-off-by: Josef Bacik <jbacik@fusionio.com>
fs/btrfs/transaction.c

index a5764aeb45498d68226004698f22e4bf0b520cc7..de774580134f2052b27a6bde0fe1b7d1e37a8abb 100644 (file)
@@ -707,23 +707,13 @@ static int __btrfs_end_transaction(struct btrfs_trans_handle *trans,
 int btrfs_end_transaction(struct btrfs_trans_handle *trans,
                          struct btrfs_root *root)
 {
-       int ret;
-
-       ret = __btrfs_end_transaction(trans, root, 0);
-       if (ret)
-               return ret;
-       return 0;
+       return __btrfs_end_transaction(trans, root, 0);
 }
 
 int btrfs_end_transaction_throttle(struct btrfs_trans_handle *trans,
                                   struct btrfs_root *root)
 {
-       int ret;
-
-       ret = __btrfs_end_transaction(trans, root, 1);
-       if (ret)
-               return ret;
-       return 0;
+       return __btrfs_end_transaction(trans, root, 1);
 }
 
 int btrfs_end_transaction_dmeta(struct btrfs_trans_handle *trans,