RFR: 8340081: Test java/foreign/TestLinker.java failed failed: missing permission java.lang.foreign.native.threshold.power.fill
Jaikiran Pai
jpai at openjdk.org
Fri Sep 13 06:35:05 UTC 2024
On Fri, 13 Sep 2024 06:25:48 GMT, Per Minborg <pminborg at openjdk.org> wrote:
> This PR fixes a regression introduced by https://github.com/openjdk/jdk/pull/20848
src/java.base/share/classes/jdk/internal/foreign/SegmentBulkOperations.java line 313:
> 311: // The returned value is in the interval [0, 2^30]
> 312: static int powerOfPropertyOr(String name, int defaultPower) {
> 313: final String property = GetPropertyAction.privilegedGetProperty(PROPERTY_PATH + name);
Hello Per, `sun.security.action.GetIntegerAction.privilegedGetProperty(PROPERTY_PATH + name, defaultPower)` could avoid the null checks and the try blocks here.
-------------
PR Review Comment: https://git.openjdk.org/jdk/pull/20983#discussion_r1758259798
More information about the core-libs-dev
mailing list