Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(664)

Unified Diff: third_party/WebKit/Source/core/workers/WorkerBackingThread.cpp

Issue 2703183002: Factor out gin::IsolateHolder's constructor
Patch Set: fix WorkerBackingThread Created 3 years, 10 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « third_party/WebKit/Source/bindings/core/v8/V8PerIsolateData.cpp ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: third_party/WebKit/Source/core/workers/WorkerBackingThread.cpp
diff --git a/third_party/WebKit/Source/core/workers/WorkerBackingThread.cpp b/third_party/WebKit/Source/core/workers/WorkerBackingThread.cpp
index 624747ee0b974c1efc6280a9b6b0cbc8278ba8fe..d5a8ac180922e535452df1ec1f546c39b54d2393 100644
--- a/third_party/WebKit/Source/core/workers/WorkerBackingThread.cpp
+++ b/third_party/WebKit/Source/core/workers/WorkerBackingThread.cpp
@@ -61,8 +61,10 @@ WorkerBackingThread::~WorkerBackingThread() {}
void WorkerBackingThread::initialize() {
DCHECK(!m_isolate);
m_backingThread->initialize();
- m_isolate = V8PerIsolateData::initialize(
- m_backingThread->platformThread().getWebTaskRunner());
+ WebTaskRunner* taskRunner =
+ backingThread().platformThread().getWebTaskRunner();
+ m_isolate = V8PerIsolateData::initialize(WTF::makeUnique<gin::IsolateHolder>(
+ taskRunner ? taskRunner->toSingleThreadTaskRunner() : nullptr));
addWorkerIsolate(m_isolate);
V8Initializer::initializeWorker(m_isolate);
« no previous file with comments | « third_party/WebKit/Source/bindings/core/v8/V8PerIsolateData.cpp ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698