diff -r d31b7cc371ef -r 77d9c0f1c19f jdk/src/windows/classes/sun/nio/fs/WindowsSecurityDescriptor.java --- a/jdk/src/windows/classes/sun/nio/fs/WindowsSecurityDescriptor.java Thu Jan 13 22:21:58 2011 -0800 +++ b/jdk/src/windows/classes/sun/nio/fs/WindowsSecurityDescriptor.java Fri Jan 28 09:28:43 2011 +0000 @@ -214,7 +214,7 @@ // map flags byte aceFlags = unsafe.getByte(aceAddress + OFFSETOF_FLAGS); - Set flags = new HashSet(); + Set flags = EnumSet.noneOf(AclEntryFlag.class); if ((aceFlags & OBJECT_INHERIT_ACE) != 0) flags.add(AclEntryFlag.FILE_INHERIT); if ((aceFlags & CONTAINER_INHERIT_ACE) != 0) @@ -226,7 +226,7 @@ // map access mask int mask = unsafe.getInt(aceAddress + OFFSETOF_ACCESS_MASK); - Set perms = new HashSet(); + Set perms = EnumSet.noneOf(AclEntryPermission.class); if ((mask & FILE_READ_DATA) > 0) perms.add(AclEntryPermission.READ_DATA); if ((mask & FILE_WRITE_DATA) > 0) @@ -378,7 +378,7 @@ AclInformation aclInfo = GetAclInformation(aclAddress); aceCount = aclInfo.aceCount(); } - ArrayList result = new ArrayList(aceCount); + ArrayList result = new ArrayList<>(aceCount); // decode each of the ACEs to AclEntry objects for (int i=0; i