# HG changeset patch # User yan # Date 1250062355 25200 # Node ID 44c8157997f521201b2f7c4d057ff898171c962d # Parent f3a7b8b75bdf5c4d2861ebfbd802d29cc4482d0c# Parent dd9363188303c99b160989148d2cb7fc6e8fc56b Merge diff -r f3a7b8b75bdf -r 44c8157997f5 jdk/src/windows/native/sun/windows/awt_Toolkit.cpp --- a/jdk/src/windows/native/sun/windows/awt_Toolkit.cpp Thu Aug 06 10:25:18 2009 -0700 +++ b/jdk/src/windows/native/sun/windows/awt_Toolkit.cpp Wed Aug 12 00:32:35 2009 -0700 @@ -1596,18 +1596,18 @@ } JNIEnv* AwtToolkit::m_env; -HANDLE AwtToolkit::m_thread; +DWORD AwtToolkit::m_threadId; void AwtToolkit::SetEnv(JNIEnv *env) { if (m_env != NULL) { // If already cashed (by means of embeddedInit() call). return; } - m_thread = GetCurrentThread(); + m_threadId = GetCurrentThreadId(); m_env = env; } JNIEnv* AwtToolkit::GetEnv() { - return (m_env == NULL || m_thread != GetCurrentThread()) ? + return (m_env == NULL || m_threadId != GetCurrentThreadId()) ? (JNIEnv*)JNU_GetEnv(jvm, JNI_VERSION_1_2) : m_env; } diff -r f3a7b8b75bdf -r 44c8157997f5 jdk/src/windows/native/sun/windows/awt_Toolkit.h --- a/jdk/src/windows/native/sun/windows/awt_Toolkit.h Thu Aug 06 10:25:18 2009 -0700 +++ b/jdk/src/windows/native/sun/windows/awt_Toolkit.h Wed Aug 12 00:32:35 2009 -0700 @@ -442,7 +442,7 @@ private: static JNIEnv *m_env; - static HANDLE m_thread; + static DWORD m_threadId; public: static void SetEnv(JNIEnv *env); static JNIEnv* GetEnv();