RFR: 8289763: Remove NULL check in CDSProtectionDomain::init_security_info()
Calvin Cheung
ccheung at openjdk.org
Wed Jul 6 04:37:30 UTC 2022
On Tue, 5 Jul 2022 18:28:11 GMT, Ioi Lam <iklam at openjdk.org> wrote:
> Please review this trivial clean up. I removed the unnecessary NULL check, and replaced the `CHECK_(pd)` with `CHECK_NH` to make the code cleaner.
>
> It's easier to view the changes by ignoring whitespace differences.
The cleanup of CHECK_ looks good. Thanks.
src/hotspot/share/cds/cdsProtectionDomain.cpp line 52:
> 50: Handle pd;
> 51:
> 52: if (ik != NULL) {
Since the null check for ik has been removed, I'm wondering if it makes sense to add an assert that ik is non-null?
(I noticed the caller already has a null check before calling the function.)
-------------
PR: https://git.openjdk.org/jdk/pull/9380
More information about the hotspot-runtime-dev
mailing list