Chromium Code Reviews| Index: Source/core/workers/WorkerThread.cpp |
| diff --git a/Source/core/workers/WorkerThread.cpp b/Source/core/workers/WorkerThread.cpp |
| index a956a8221a1fa9e9086eca92b299f28ada1f3af7..ebf5bb290355314f707c987bd30852e06bfd2b4c 100644 |
| --- a/Source/core/workers/WorkerThread.cpp |
| +++ b/Source/core/workers/WorkerThread.cpp |
| @@ -29,6 +29,7 @@ |
| #include "core/workers/WorkerThread.h" |
| #include "bindings/v8/ScriptSourceCode.h" |
| +#include "core/dom/Microtask.h" |
| #include "core/inspector/InspectorInstrumentation.h" |
| #include "core/workers/DedicatedWorkerGlobalScope.h" |
| #include "core/workers/WorkerClients.h" |
| @@ -113,6 +114,8 @@ void WorkerThread::workerThread() |
| ThreadState::attach(); |
| m_workerGlobalScope = createWorkerGlobalScope(m_startupData.release()); |
| m_runLoop.setWorkerGlobalScope(workerGlobalScope()); |
| + // Call performCheckpoint now to call ensureDomInJSContext. |
| + Microtask::performCheckpoint(); |
|
adamk
2014/03/28 17:55:05
I don't understand why this is here.
|
| if (m_runLoop.terminated()) { |
| // The worker was terminated before the thread had a chance to run. Since the context didn't exist yet, |