From f99d49adf527fa6f7a9c42257fa76bca6b8df1e3 Mon Sep 17 00:00:00 2001 From: Jesper Juhl Date: Mon, 7 Nov 2005 01:01:34 -0800 Subject: [PATCH] kfree cleanup: fs This is the fs/ part of the big kfree cleanup patch. Remove pointless checks for NULL prior to calling kfree() in fs/. Signed-off-by: Jesper Juhl Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds --- fs/jbd/transaction.c | 9 +++------ 1 file changed, 3 insertions(+), 6 deletions(-) (limited to 'fs/jbd/transaction.c') diff --git a/fs/jbd/transaction.c b/fs/jbd/transaction.c index 13cb05bf604..429f4b263cf 100644 --- a/fs/jbd/transaction.c +++ b/fs/jbd/transaction.c @@ -227,8 +227,7 @@ repeat_locked: spin_unlock(&transaction->t_handle_lock); spin_unlock(&journal->j_state_lock); out: - if (new_transaction) - kfree(new_transaction); + kfree(new_transaction); return ret; } @@ -725,8 +724,7 @@ done: journal_cancel_revoke(handle, jh); out: - if (frozen_buffer) - kfree(frozen_buffer); + kfree(frozen_buffer); JBUFFER_TRACE(jh, "exit"); return error; @@ -905,8 +903,7 @@ repeat: jbd_unlock_bh_state(bh); out: journal_put_journal_head(jh); - if (committed_data) - kfree(committed_data); + kfree(committed_data); return err; } -- cgit v1.2.3