RFR: 8296741: Illegal X400Address and EDIPartyName should not be created [v2]
Xue-Lei Andrew Fan
xuelei at openjdk.org
Thu Nov 10 03:56:28 UTC 2022
On Thu, 10 Nov 2022 02:32:42 GMT, Weijun Wang <weijun at openjdk.org> wrote:
>> src/java.base/share/classes/sun/security/x509/EDIPartyName.java line 66:
>>
>>> 64: public EDIPartyName(String assignerName, String partyName) {
>>> 65: this.assigner = assignerName;
>>> 66: this.party = Objects.requireNonNull(partyName);
>>
>> It looks like this constructor is not used. Is if safe to remove it?
>
> It's not used inside JDK. But for completeness it sounds there should be a way to create one with an assigner.
Unused code means useless cost. For private package, it may be nice to keep compact and no unused code. As the class is public, I'm fine to leave as it is if you want to.
-------------
PR: https://git.openjdk.org/jdk/pull/11071
More information about the security-dev
mailing list