提交 f72f2d2e 编写于 作者: S Steven Whitehouse

GFS2: Don't "get" xattrs for ACLs when ACLs are turned off

This is to match ext3 behaviour. We should not allow getting of
xattrs relating to ACLs when ACLs are turned off.
Reported-by: NNate Straz <nstraz@redhat.com>
Signed-off-by: NSteven Whitehouse <swhiteho@redhat.com>
上级 ed4878e8
...@@ -236,10 +236,14 @@ static int gfs2_xattr_system_get(struct dentry *dentry, const char *name, ...@@ -236,10 +236,14 @@ static int gfs2_xattr_system_get(struct dentry *dentry, const char *name,
void *buffer, size_t size, int xtype) void *buffer, size_t size, int xtype)
{ {
struct inode *inode = dentry->d_inode; struct inode *inode = dentry->d_inode;
struct gfs2_sbd *sdp = GFS2_SB(inode);
struct posix_acl *acl; struct posix_acl *acl;
int type; int type;
int error; int error;
if (!sdp->sd_args.ar_posix_acl)
return -EOPNOTSUPP;
type = gfs2_acl_type(name); type = gfs2_acl_type(name);
if (type < 0) if (type < 0)
return type; return type;
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册