AwtDropTarget::~AwtDropTarget() { JNIEnv* env = (JNIEnv *)JNU_GetEnv(jvm, JNI_VERSION_1_2); env->DeleteGlobalRef(m_target); env->DeleteGlobalRef(m_dtcp); ::CloseHandle(m_mutex); UnloadCache(); }
AwtDropTarget::~AwtDropTarget() { JNIEnv* env = (JNIEnv *)JNU_GetEnv(jvm, JNI_VERSION_1_2); // fix for 6212440: on application shutdown, this object's // destruction might be suppressed due to dangling COM references. // On destruction, VM might be shut down already, so we should make // a null check on env. if (env) { env->DeleteGlobalRef(m_target); env->DeleteGlobalRef(m_dtcp); } ::CloseHandle(m_mutex); UnloadCache(); }