Message ID | 20150305174619.GA13294@mwanda (mailing list archive) |
---|---|
State | New, archived |
Headers | show |
On Thu, Mar 05, 2015 at 08:46:19PM +0300, Dan Carpenter wrote: > The code at the "out" label assumes that "default_acl" and "acl" are > NULL, but actually the pointers can be NULL, unitialized, or freed. > > Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com> Reviewed-by: Mark Fasheh <mfasheh@suse.de> -- Mark Fasheh
diff --git a/fs/ocfs2/refcounttree.c b/fs/ocfs2/refcounttree.c index ee541f9..df3a500 100644 --- a/fs/ocfs2/refcounttree.c +++ b/fs/ocfs2/refcounttree.c @@ -4276,7 +4276,7 @@ static int ocfs2_reflink(struct dentry *old_dentry, struct inode *dir, error = posix_acl_create(dir, &mode, &default_acl, &acl); if (error) { mlog_errno(error); - goto out; + return error; } error = ocfs2_create_inode_in_orphan(dir, mode,
The code at the "out" label assumes that "default_acl" and "acl" are NULL, but actually the pointers can be NULL, unitialized, or freed. Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>