classpath-patches
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [cp-patches] Patch: java/lang/Runtime.java


From: Archie Cobbs
Subject: Re: [cp-patches] Patch: java/lang/Runtime.java
Date: Mon, 6 Sep 2004 20:25:35 -0500 (CDT)

Mark Wielaard wrote:
> It is per VM even since JNI doesn't allow a given JNI native library to
> be loaded by more than one class loader.

This silly restriction is only because dlopen()'ing the same file
twice doesn't map in the library twice, instead you just get another
reference to the already-mapped memory. This is really a deficiency
in the dlopen() API IMHO that the JVM inherits and consequently is
limited by.

If you could dlopen(..., RTLD_COPY) or whatever then this problem could
go away... also, a gross hack would involve copying the library to /tmp,
dlopen()'ing it, then removing it.

-Archie

__________________________________________________________________________
Archie Cobbs      *        CTO, Awarix        *      http://www.awarix.com




reply via email to

[Prev in Thread] Current Thread [Next in Thread]