diff options
author | Barry Naujok <bnaujok@sgi.com> | 2008-04-22 03:34:31 -0400 |
---|---|---|
committer | Lachlan McIlroy <lachlan@redback.melbourne.sgi.com> | 2008-04-29 01:54:55 -0400 |
commit | e8b0ebaa115ac46b21622b103c29927f5805aeaa (patch) | |
tree | 8c19012d6efadfa17192d2b39bb73140ad3e7d45 /fs/xfs/xfs_acl.c | |
parent | 5df78e73d328e870a1cd8a9e0f39bf094e42ce9d (diff) |
[XFS] Cleanup xfs_attr a bit with xfs_name and remove cred
SGI-PV: 976035
SGI-Modid: xfs-linux-melb:xfs-kern:30913a
Signed-off-by: Barry Naujok <bnaujok@sgi.com>
Signed-off-by: Christoph Hellwig <hch@infradead.org>
Signed-off-by: Lachlan McIlroy <lachlan@sgi.com>
Diffstat (limited to 'fs/xfs/xfs_acl.c')
-rw-r--r-- | fs/xfs/xfs_acl.c | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/fs/xfs/xfs_acl.c b/fs/xfs/xfs_acl.c index 796e76ef2713..ebee3a4f703a 100644 --- a/fs/xfs/xfs_acl.c +++ b/fs/xfs/xfs_acl.c | |||
@@ -334,14 +334,15 @@ xfs_acl_iaccess( | |||
334 | { | 334 | { |
335 | xfs_acl_t *acl; | 335 | xfs_acl_t *acl; |
336 | int rval; | 336 | int rval; |
337 | struct xfs_name acl_name = {SGI_ACL_FILE, SGI_ACL_FILE_SIZE}; | ||
337 | 338 | ||
338 | if (!(_ACL_ALLOC(acl))) | 339 | if (!(_ACL_ALLOC(acl))) |
339 | return -1; | 340 | return -1; |
340 | 341 | ||
341 | /* If the file has no ACL return -1. */ | 342 | /* If the file has no ACL return -1. */ |
342 | rval = sizeof(xfs_acl_t); | 343 | rval = sizeof(xfs_acl_t); |
343 | if (xfs_attr_fetch(ip, SGI_ACL_FILE, SGI_ACL_FILE_SIZE, | 344 | if (xfs_attr_fetch(ip, &acl_name, (char *)acl, &rval, |
344 | (char *)acl, &rval, ATTR_ROOT | ATTR_KERNACCESS, cr)) { | 345 | ATTR_ROOT | ATTR_KERNACCESS)) { |
345 | _ACL_FREE(acl); | 346 | _ACL_FREE(acl); |
346 | return -1; | 347 | return -1; |
347 | } | 348 | } |
@@ -579,7 +580,7 @@ xfs_acl_get_attr( | |||
579 | *error = xfs_attr_get(xfs_vtoi(vp), | 580 | *error = xfs_attr_get(xfs_vtoi(vp), |
580 | kind == _ACL_TYPE_ACCESS ? | 581 | kind == _ACL_TYPE_ACCESS ? |
581 | SGI_ACL_FILE : SGI_ACL_DEFAULT, | 582 | SGI_ACL_FILE : SGI_ACL_DEFAULT, |
582 | (char *)aclp, &len, flags, sys_cred); | 583 | (char *)aclp, &len, flags); |
583 | if (*error || (flags & ATTR_KERNOVAL)) | 584 | if (*error || (flags & ATTR_KERNOVAL)) |
584 | return; | 585 | return; |
585 | xfs_acl_get_endian(aclp); | 586 | xfs_acl_get_endian(aclp); |