Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

scijava native loader must be within the same classloader as the consuming class #49

Open
wasabii opened this issue Dec 14, 2023 · 1 comment

Comments

@wasabii
Copy link

wasabii commented Dec 14, 2023

The JNI specification requires that the classloader of the caller of System.loadLibrary be the same classloader of the class attempting to consume the native methods. Since native-lib-loader tends to be a dependency of other libraries, and it is the mechanism which eventually invokes System.loadLibrary, it must be the case that all classes using native-lib-loader be loaded by the same class loader that loaded it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants