From c6d23ac2bb439d144d10e040cea8f72cfafeb6b2 Mon Sep 17 00:00:00 2001 From: Andrew Morton Date: Wed, 20 Feb 2013 13:13:48 +1100 Subject: [PATCH] ocfs2-remove-kfree-redundant-null-checks-fix revert dubious change in ocfs2_begin_truncate_log_recovery() Cc: Joel Becker Cc: Mark Fasheh Cc: Tim Gardner Signed-off-by: Andrew Morton --- fs/ocfs2/alloc.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/fs/ocfs2/alloc.c b/fs/ocfs2/alloc.c index 83a1a1d9d1bf..b8a9d87231b1 100644 --- a/fs/ocfs2/alloc.c +++ b/fs/ocfs2/alloc.c @@ -6134,7 +6134,7 @@ bail: iput(tl_inode); brelse(tl_bh); - if (status < 0) { + if (status < 0 && (*tl_copy)) { kfree(*tl_copy); *tl_copy = NULL; mlog_errno(status); -- 2.39.5