diff mbox

[2/4] Btrfs: trivial cleanup: setup ret with 0 directly in btrfs_wait_for_commit

Message ID 505FAD8E.2070506@gmail.com (mailing list archive)
State New, archived
Headers show

Commit Message

Wang Sheng-Hui Sept. 24, 2012, 12:47 a.m. UTC
trivial code cleanup.

Signed-off-by: Wang Sheng-Hui <shhuiw@gmail.com>
---
 fs/btrfs/transaction.c |    3 +--
 1 files changed, 1 insertions(+), 2 deletions(-)
diff mbox

Patch

diff --git a/fs/btrfs/transaction.c b/fs/btrfs/transaction.c
index 8fcc501..469a8b6 100644
--- a/fs/btrfs/transaction.c
+++ b/fs/btrfs/transaction.c
@@ -420,9 +420,8 @@  static noinline void wait_for_commit(struct btrfs_root *root,
 int btrfs_wait_for_commit(struct btrfs_root *root, u64 transid)
 {
 	struct btrfs_transaction *cur_trans = NULL, *t;
-	int ret;
+	int ret = 0;
 
-	ret = 0;
 	if (transid) {
 		if (transid <= root->fs_info->last_trans_committed)
 			goto out;