changeset 5058:3712e86c7317

RT-32809: Worker tests (DRT) are failing after fix for RT-21460
author Vasiliy Baranov <vasiliy.baranov@oracle.com>
date Thu, 12 Sep 2013 15:07:03 +0400
parents 45efea44f8dd
children 2e7136afdc8f
files modules/web/src/main/native/Source/WebCore/workers/WorkerThread.cpp
diffstat 1 files changed, 7 insertions(+), 7 deletions(-) [+]
line wrap: on
line diff
--- a/modules/web/src/main/native/Source/WebCore/workers/WorkerThread.cpp	Thu Sep 12 15:05:30 2013 +0400
+++ b/modules/web/src/main/native/Source/WebCore/workers/WorkerThread.cpp	Thu Sep 12 15:07:03 2013 +0400
@@ -149,6 +149,13 @@
 
 void WorkerThread::workerThread()
 {
+#if PLATFORM(JAVA)
+    {
+        void* env;
+        jvm->AttachCurrentThreadAsDaemon(&env, 0);
+    }
+#endif
+
     {
         MutexLocker lock(m_threadCreationMutex);
         m_workerContext = createWorkerContext(m_startupData->m_scriptURL, m_startupData->m_userAgent, m_startupData->m_groupSettings.release(), m_startupData->m_contentSecurityPolicy, m_startupData->m_contentSecurityPolicyType, m_startupData->m_topOrigin.release());
@@ -160,13 +167,6 @@
         }
     }
 
-#if PLATFORM(JAVA)
-    {
-        void* env;
-        jvm->AttachCurrentThreadAsDaemon(&env, 0);
-    }
-#endif
-
     WorkerScriptController* script = m_workerContext->script();
 #if ENABLE(INSPECTOR)
     InspectorInstrumentation::willEvaluateWorkerScript(workerContext(), m_startupData->m_startMode);