This is the mail archive of the java@gcc.gnu.org mailing list for the Java project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: classloading from so


>>>>> "Hans" == Boehm, Hans <hans_boehm@hp.com> writes:

Hans> Hopefully the class loader is referenced from a static variable
Hans> in the loaded library?  Thus this can never happen because the
Hans> garbage collector views the library static data as roots and
Hans> would thus never collect the class loader?

That's a good point, which I hadn't considered.

For a class loaded by SharedLibLoader we could register the `loader'
field as a disappearing link.  Would that work correctly?

Hans> I say "hopefully" because I'm pretty sure we have no mechanism
Hans> to test whether a static method of some class is still on a call
Hans> stack somewhere.  Thus if we could unload such classes, we could
Hans> probably unload them while the code is still running, which
Hans> would be a bug, not to mention security hole.

Also a good point.  There has to be a way to fix this though.

Tom


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]