Hello,

Please review this fix for 9.

A string which contains a number of principals can be passed to constructor of DelegationPermission. The class parses this string, and extracts principals. But hashCode() method in DelegationPermission uses Permission.getName() to calculate a hash. Permission.getName() method returns the original string which was passed to constructor. As a result, semantically equal instances of DelegationPermission may return different hash codes.

Changes:
- updated hashCode() method
- re-factored equals() and implies() method
- removed some unused and commented code in DelegationPermission class
- added a test

Bug: https://bugs.openjdk.java.net/browse/JDK-8129575
Webrev: http://cr.openjdk.java.net/~asmotrak/delegation_permission/webrev.01/

Artem

Reply via email to