Details
-
Bug
-
Status: Resolved
-
Minor
-
Resolution: Not A Problem
-
2.6.4
-
None
-
None
-
Linux
Description
In jni_helper.c in the getJNIEnv function
The “THREAD_LOCAL_STORAGE_SET_QUICK(env);” Macro is in the wrong location;
It should precede the “threadLocalStorageSet(env)” as follows ::
THREAD_LOCAL_STORAGE_SET_QUICK(env);
if (threadLocalStorageSet(env))
{ return NULL; }AND IN “thread_local_storage.h” the macro: “THREAD_LOCAL_STORAGE_SET_QUICK”
should be as follows ::
#ifdef HAVE_BETTER_TLS
#define THREAD_LOCAL_STORAGE_GET_QUICK() \
static __thread JNIEnv *quickTlsEnv = NULL; \
{ \
if (quickTlsEnv)
\
}
#define THREAD_LOCAL_STORAGE_SET_QUICK(env) \
{ \ quickTlsEnv = (env); \ return env; }#else
#define THREAD_LOCAL_STORAGE_GET_QUICK()
#define THREAD_LOCAL_STORAGE_SET_QUICK(env)
#endif