src/solaris/classes/sun/nio/fs/SolarisAclFileAttributeView.java

Print this page

        

*** 102,116 **** throw new ProviderMismatchException(); UnixUserPrincipals.User user = (UnixUserPrincipals.User)who; int uid; if (user.isSpecial()) { uid = -1; ! if (who.getName().equals(UnixUserPrincipals.SPECIAL_OWNER.getName())) flags |= ACE_OWNER; ! else if (who.getName().equals(UnixUserPrincipals.SPECIAL_GROUP.getName())) ! flags |= ACE_GROUP; ! else if (who.getName().equals(UnixUserPrincipals.SPECIAL_EVERYONE.getName())) flags |= ACE_EVERYONE; else throw new AssertionError("Unable to map special identifier"); } else { if (user instanceof UnixUserPrincipals.Group) { --- 102,116 ---- throw new ProviderMismatchException(); UnixUserPrincipals.User user = (UnixUserPrincipals.User)who; int uid; if (user.isSpecial()) { uid = -1; ! if (who == UnixUserPrincipals.SPECIAL_OWNER) flags |= ACE_OWNER; ! else if (who == UnixUserPrincipals.SPECIAL_GROUP) ! flags |= (ACE_GROUP | ACE_IDENTIFIER_GROUP); ! else if (who == UnixUserPrincipals.SPECIAL_EVERYONE) flags |= ACE_EVERYONE; else throw new AssertionError("Unable to map special identifier"); } else { if (user instanceof UnixUserPrincipals.Group) {
*** 279,289 **** aceFlags.add(AclEntryFlag.FILE_INHERIT); if ((flags & ACE_DIRECTORY_INHERIT_ACE) > 0) aceFlags.add(AclEntryFlag.DIRECTORY_INHERIT); if ((flags & ACE_NO_PROPAGATE_INHERIT_ACE) > 0) aceFlags.add(AclEntryFlag.NO_PROPAGATE_INHERIT); ! if ((flags & ACE_INHERIT_ONLY_ACE ) > 0) aceFlags.add(AclEntryFlag.INHERIT_ONLY); // build the ACL entry and add it to the list AclEntry ace = AclEntry.newBuilder() .setType(aceType) --- 279,289 ---- aceFlags.add(AclEntryFlag.FILE_INHERIT); if ((flags & ACE_DIRECTORY_INHERIT_ACE) > 0) aceFlags.add(AclEntryFlag.DIRECTORY_INHERIT); if ((flags & ACE_NO_PROPAGATE_INHERIT_ACE) > 0) aceFlags.add(AclEntryFlag.NO_PROPAGATE_INHERIT); ! if ((flags & ACE_INHERIT_ONLY_ACE) > 0) aceFlags.add(AclEntryFlag.INHERIT_ONLY); // build the ACL entry and add it to the list AclEntry ace = AclEntry.newBuilder() .setType(aceType)