SUGGESTED FIX
------- awt_DnDDS.cpp -------
*** - Sun Jul 10 22:09:20 2005
--- awt_DnDDS.cpp Sun Jul 10 22:08:28 2005
***************
*** 166,175 ****
AwtDragSource::~AwtDragSource() {
JNIEnv* env = (JNIEnv *)JNU_GetEnv(jvm, JNI_VERSION_1_2);
! env->DeleteGlobalRef(m_peer);
! env->DeleteGlobalRef(m_component);
! env->DeleteGlobalRef(m_transferable);
! env->DeleteGlobalRef(m_formatMap);
::CloseHandle(m_mutex);
--- 166,181 ----
AwtDragSource::~AwtDragSource() {
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_peer);
! env->DeleteGlobalRef(m_component);
! env->DeleteGlobalRef(m_transferable);
! env->DeleteGlobalRef(m_formatMap);
! }
::CloseHandle(m_mutex);
------- awt_DnDDT.cpp -------
*** - Sun Jul 10 22:10:04 2005
--- awt_DnDDT.cpp Sun Jul 10 22:08:27 2005
***************
*** 60,67 ****
AwtDropTarget::~AwtDropTarget() {
JNIEnv* env = (JNIEnv *)JNU_GetEnv(jvm, JNI_VERSION_1_2);
! env->DeleteGlobalRef(m_target);
! env->DeleteGlobalRef(m_dtcp);
::CloseHandle(m_mutex);
--- 60,73 ----
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);
***************
*** 857,863 ****
m_formats = (FORMATETC *)NULL;
m_nformats = 0;
! env->DeleteGlobalRef(m_cfFormats);
m_cfFormats = NULL;
if (!IsLocalDnD()) {
--- 863,876 ----
m_formats = (FORMATETC *)NULL;
m_nformats = 0;
! // fix for 6212440: on application shutdown, this object's
! // destruction might be suppressed due to dangling COM references.
! // This method is called from the destructor.
! // On destruction, VM might be shut down already, so we should make
! // a null check on env.
! if (env) {
! env->DeleteGlobalRef(m_cfFormats);
! }
m_cfFormats = NULL;
if (!IsLocalDnD()) {
###@###.### 2005-07-10 18:11:35 GMT
|