提交 b99835c1 编写于 作者: J Jan Kara 提交者: Mark Fasheh

ocfs2: Let inode be really deleted when ocfs2_mknod_locked() fails

We forgot to set i_nlink to 0 when returning due to error from ocfs2_mknod_locked()
and thus inode was not properly released via ocfs2_delete_inode() (e.g. claimed
space was not released). Fix it.
Signed-off-by: NJan Kara <jack@suse.cz>
Signed-off-by: NJoel Becker <joel.becker@oracle.com>
Signed-off-by: NMark Fasheh <mfasheh@suse.com>
上级 87cfa004
......@@ -491,8 +491,10 @@ static int ocfs2_mknod_locked(struct ocfs2_super *osb,
brelse(*new_fe_bh);
*new_fe_bh = NULL;
}
if (inode)
if (inode) {
clear_nlink(inode);
iput(inode);
}
}
mlog_exit(status);
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册