-
Notifications
You must be signed in to change notification settings - Fork 8
Open
Description
Ran the Java interface to GMSEC API 4.6-RH7 with the -Xcheck:jni to make sure it is making valid JNI calls. Used a ConnectionManager to make a request with a call back. It turns out that GMSEC API was not correctly using JNI.
This is the output from -Xcheck:jni:
WARNING in native method: JNI call made with exception pending
FATAL ERROR in native method: Bad global or local ref passed to JNI
The is the stack of the thread that caused the seg fault:
Stack: [0x00007f3145cf7000,0x00007f31464f7000], sp=0x00007f31464f5860, free space=8186k
Native frames: (J=compiled Java code, j=interpreted, Vv=VM code, C=native code)
C [libc.so.6+0x37bc7] abort+0x297
V [libjvm.so+0x71aa8b] jniCheck::validate_handle(JavaThread*, _jobject*)+0xab
V [libjvm.so+0x71ae25] jniCheck::validate_class(JavaThread*, _jclass*, bool) [clone .constprop.176]+0x15
V [libjvm.so+0x71be15] checked_jni_GetStaticFieldID+0x75
C [libgmsec_jni.so+0xb7d30] JNIEnv_::GetStaticFieldID(_jclass*, char const*, char const*)+0x38
C [libgmsec_jni.so+0xba67f] gmsec::api::jni::convertEvent(JNIEnv_*, gmsec::api::Connection::ConnectionEvent)+0x109
C [libgmsec_jni.so+0xf54f2] gmsec::api::jni::CxxConnMgrReplyCallbackProxy::onEvent(gmsec::api::mist::ConnectionManager&, gmsec::api::Status const&, gmsec::api::Connection::ConnectionEvent)+0x3bc
C [libGMSECAPI.so+0x37e1c5] gmsec::api::mist::internal::CMReplyCallback::onEvent(gmsec::api::Connection&, gmsec::api::Status const&, gmsec::api::Connection::ConnectionEvent)+0x45
C [libGMSECAPI.so+0x344cca] gmsec::api::internal::InternalConnection::replyEvent(gmsec::api::ReplyCallback*, gmsec::api::Status const&, gmsec::api::Connection::ConnectionEvent)+0x68
C [libGMSECAPI.so+0x36742f] gmsec::api::internal::RequestShared::sendRequests()+0x20d
C [libGMSECAPI.so+0x367008] gmsec::api::internal::RequestShared::run()+0x3cc
C [libGMSECAPI.so+0x366af0] gmsec::api::internal::runRequestThread(gmsec::api::util::StdSharedPtr<gmsec::api::internal::RequestShared>)+0x20
C [libGMSECAPI.so+0x34d465] gmsec::api::util::StdThread::FunctionInvoker<void (*)(gmsec::api::util::StdSharedPtr<gmsec::api::internal::RequestShared>), gmsec::api::util::StdSharedPtr<gmsec::api::internal::RequestShared> >::_invoke()+0x35
C [libGMSECAPI.so+0x3e3210] gmsec::api::util::StdThread::Invoker::invoke()+0xa6
C [libGMSECAPI.so+0x3e1c3f] gmsec::api::util::StdThread::process0(void*)+0x21
C [libpthread.so.0+0x7ea5] start_thread+0xc5
Metadata
Metadata
Assignees
Labels
No labels