RFR: 8311170: Simplify and modernize equals and hashCode in security area [v12]

Pavel Rappo prappo at openjdk.org
Fri Aug 4 11:04:45 UTC 2023


On Fri, 4 Aug 2023 09:35:54 GMT, Pavel Rappo <prappo at openjdk.org> wrote:

>> src/java.base/share/classes/com/sun/crypto/provider/PBKDF2KeyImpl.java line 272:
>> 
>>> 270:             }
>>> 271: 
>>> 272:             if (!(that.getAlgorithm().equalsIgnoreCase(getAlgorithm()))){
>> 
>> why removing the space before the "{"?
>
> It surprises me as much as it probably surprises you. Looks like a sloppy merge (821f617ffae) on my part.

I retraced my steps to see how the merge introduced that artefact. This might be useful to others too.

The original merge was done via an IDE, which has this (usually) helpful 1-click feature called "Resolve Simple Conflicts". It's that feature that ate that whitespace character. To its credit, the rest of the resolution seems to have been done correctly. When I examined the original merge before pushing it to the PR, I didn't spot that whitespace; my bad. I'll reintroduce it.

Thanks for your careful review.

-------------

PR Review Comment: https://git.openjdk.org/jdk/pull/14738#discussion_r1284285619



More information about the security-dev mailing list