提交 90947ef2 编写于 作者: J Jeff Mahoney 提交者: Linus Torvalds

[PATCH] reiserfs: fix potential (unlikely) oops in reiserfs_get_acl

This fixes a potential oops if there is an error reported by
posix_acl_from_disk().  This is mostly theoretical due to the use of
magics and checksums in xattrs, but is still possible.
Signed-off-by: NJeff Mahoney <jeffm@suse.com>
Signed-off-by: NLinus Torvalds <torvalds@osdl.org>
上级 326a6257
......@@ -228,7 +228,8 @@ struct posix_acl *reiserfs_get_acl(struct inode *inode, int type)
acl = ERR_PTR(retval);
} else {
acl = posix_acl_from_disk(value, retval);
*p_acl = posix_acl_dup(acl);
if (!IS_ERR(acl))
*p_acl = posix_acl_dup(acl);
}
kfree(value);
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册