RFR: 8315891: java/foreign/TestLinker.java failed with "error occurred while instantiating class TestLinker: null"

Jorn Vernee jvernee at openjdk.org
Fri Sep 8 10:29:12 UTC 2023


On Fri, 8 Sep 2023 10:19:05 GMT, Maurizio Cimadamore <mcimadamore at openjdk.org> wrote:

> This PR adds a privileged block surrounding the request to load the fallback linker library in LibFallback.
> The lack of this block is causing test failures when platforms using the fallback linker are tested using a security manager.

src/java.base/share/classes/jdk/internal/foreign/abi/fallback/LibFallback.java line 42:

> 40:     private static boolean tryLoadLibrary() {
> 41:         return java.security.AccessController.doPrivileged(
> 42:                 new java.security.PrivilegedAction<>() {

Could use imports instead of using fully qualified names here.

src/java.base/share/classes/jdk/internal/foreign/abi/fallback/LibFallback.java line 45:

> 43:                     public Boolean run() {
> 44:                         try {
> 45:                             System.loadLibrary("jimage");

`"jimage"`?

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

PR Review Comment: https://git.openjdk.org/jdk/pull/15633#discussion_r1319675039
PR Review Comment: https://git.openjdk.org/jdk/pull/15633#discussion_r1319674145


More information about the core-libs-dev mailing list