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

Prevent loading native libraries with same basename #67

Merged
merged 2 commits into from
Mar 20, 2022
Merged

Conversation

fmeum
Copy link
Owner

@fmeum fmeum commented Mar 20, 2022

No description provided.

@fmeum fmeum force-pushed the fix-loading-twice branch 2 times, most recently from 1d5e00e to f4e77df Compare March 20, 2022 21:39
fmeum added 2 commits March 20, 2022 22:52
Loading the same library (identified by its resource path) twice should
succeed, but the second load should be a no-op so that static
initializers and JNI_OnLoad aren't run twice.

Loading two libraries sharing a basename from different paths should
result in an error as this situation is not handled consistently by all
operating systems and determining whether two libraries are truly
identical for all purposes is difficult.
@fmeum fmeum force-pushed the fix-loading-twice branch from f4e77df to a044fbf Compare March 20, 2022 21:52
@fmeum fmeum enabled auto-merge (rebase) March 20, 2022 21:57
@fmeum fmeum merged commit cdc39ba into main Mar 20, 2022
@fmeum fmeum deleted the fix-loading-twice branch March 20, 2022 22:00
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

Successfully merging this pull request may close these issues.

1 participant