From mboxrd@z Thu Jan 1 00:00:00 1970 From: Denis Cheng Date: Wed, 15 Aug 2007 23:54:44 +0800 Subject: [Cluster-devel] [PATCH] gfs2: fixed a NULL pointer assignment BUG Message-ID: <1187193284541-git-send-email-crquan@gmail.com> List-Id: To: cluster-devel.redhat.com MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Signed-off-by: Denis Cheng --- fs/gfs2/ops_fstype.c | 5 +++-- 1 files changed, 3 insertions(+), 2 deletions(-) diff --git a/fs/gfs2/ops_fstype.c b/fs/gfs2/ops_fstype.c index cf5aa50..67e2d43 100644 --- a/fs/gfs2/ops_fstype.c +++ b/fs/gfs2/ops_fstype.c @@ -301,8 +301,9 @@ static int init_sb(struct gfs2_sbd *sdp, int silent, int undo) fs_err(sdp, "can't get root dentry\n"); error = -ENOMEM; iput(inode); - } - sb->s_root->d_op = &gfs2_dops; + } else + sb->s_root->d_op = &gfs2_dops; + out: gfs2_glock_dq_uninit(&sb_gh); return error; -- 1.5.3.rc4