Index: linux-2.6.6-rc2/fs/xfs/xfs_acl.c =================================================================== --- linux-2.6.6-rc2.orig/fs/xfs/xfs_acl.c +++ linux-2.6.6-rc2/fs/xfs/xfs_acl.c @@ -148,10 +148,7 @@ posix_acl_xattr_to_xfs( return EINVAL; } } - if (xfs_acl_invalid(dest)) - return EINVAL; - - return 0; + return xfs_acl_invalid(dest); } /* @@ -249,10 +246,9 @@ xfs_acl_vget( if (!size) { error = -posix_acl_xattr_size(XFS_ACL_MAX_ENTRIES); } else { - if (xfs_acl_invalid(xfs_acl)) { - error = EINVAL; + error = xfs_acl_invalid(xfs_acl); + if (error) goto out; - } if (kind == _ACL_TYPE_ACCESS) { vattr_t va; @@ -590,7 +586,7 @@ xfs_acl_invalid( goto acl_invalid; if (aclp->acl_cnt > XFS_ACL_MAX_ENTRIES) - goto acl_invalid; + return ENOSPC; for (i = 0; i < aclp->acl_cnt; i++) { entry = &aclp->acl_entry[i];