From: Jan Kara References: fate#302681 Subject: ocfs2: Fix recovery of nodes when quota feature is disabled Patch-mainline: 2.6.29? When quota feature is disabled, uninitialized content of variable status got passed up from ocfs2_begin_quota_recovery() which could then cause problems, even more so because we queued quota recovery structure even when pointer was invalid. Signed-off-by: Jan Kara --- fs/ocfs2/journal.c | 1 + fs/ocfs2/quota_local.c | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) --- a/fs/ocfs2/journal.c +++ b/fs/ocfs2/journal.c @@ -1135,6 +1135,7 @@ skip_recovery: if (IS_ERR(qrec)) { status = PTR_ERR(qrec); mlog_errno(status); + continue; } ocfs2_queue_recovery_completion(osb->journal, rm_quota[i], NULL, NULL, qrec); --- a/fs/ocfs2/quota_local.c +++ b/fs/ocfs2/quota_local.c @@ -365,7 +365,7 @@ struct ocfs2_quota_recovery *ocfs2_begin struct inode *lqinode; struct buffer_head *bh; int type; - int status; + int status = 0; struct ocfs2_quota_recovery *rec; mlog(ML_NOTICE, "Beginning quota recovery in slot %u\n", slot_num);