On Thu, 10 Feb 2022 23:27:49 GMT, Mandy Chung <[email protected]> wrote:

> This patch removes the restriction in the raw library loading mechanism that 
> does not allow mix-n-match of loading a library as a JNI library and as a raw 
> library.
> 
> The raw library loading mechanism is designed for panama to load native 
> library essentially equivalent to dlopen/dlclose calls independent of JNI 
> library loading. If a native library is loaded as a JNI library and a raw 
> library, it will get different NativeLibrary instances. When a class loader 
> is being unloaded, JNI_Unload will be invoked but the native library may not 
> be unloaded until NativeLibrary::unload is explicitly called for the raw 
> library.

This pull request has now been integrated.

Changeset: 980d1878
Author:    Mandy Chung <[email protected]>
URL:       
https://git.openjdk.java.net/jdk/commit/980d18789139295c95ec6045539b68d1ae57bc31
Stats:     281 lines in 7 files changed: 183 ins; 66 del; 32 mod

8281335: Allow a library already loaded via System::loadLibrary to be loaded as 
a raw library

Reviewed-by: sundar, mcimadamore

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

PR: https://git.openjdk.java.net/jdk/pull/7435

Reply via email to