From: Archie Cobbs (archie@whistle.com)
Date: Fri Feb 12 1999 - 13:11:01 EST
Godmar Back writes:
> I think we should just not call non-reentrant code from JNI code;
OK, so you're going to replace all the instances of malloc(), sprintf(),
and basically every other libc call in our native code? :-)
> if it's unavoidable, the JNI code should use jthread_spinon/spinoff:
> or alternatively, lets add these functions to the jsyscall interface.
I guess if we've already forfieted on portability by using
kaffe.util.Native or whatever, then calling the spinon/spinoff
routines directly isn't much worse. Can we add the appropriate
macros to native.h?
My ulterior motive here, by the way, is to eliminate all the
potential race conditions caused by calling non-reentrant code
(like malloc()) in our native code. These are the hardest bugs to
reproduce and fix.. and right now the recursive malloc problem is
preventing us from getting Apache+Jserv working correctly.
-Archie
___________________________________________________________________________
Archie Cobbs * Whistle Communications, Inc. * http://www.whistle.com
This archive was generated by hypermail 2b29 : Sat Sep 23 2000 - 19:58:07 EDT