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

Unified Diff: content/child/service_worker/web_service_worker_registration_impl.cc

Issue 2118243002: [proof-of-concept] SW thread independent of the main thread Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: rebase Created 4 years, 4 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
Index: content/child/service_worker/web_service_worker_registration_impl.cc
diff --git a/content/child/service_worker/web_service_worker_registration_impl.cc b/content/child/service_worker/web_service_worker_registration_impl.cc
index ae2705ee0b568eb48704764e0a591b0f0746cd49..67f980a2ff72494586f41e2a478227be56ffa32f 100644
--- a/content/child/service_worker/web_service_worker_registration_impl.cc
+++ b/content/child/service_worker/web_service_worker_registration_impl.cc
@@ -57,6 +57,8 @@ WebServiceWorkerRegistrationImpl::WebServiceWorkerRegistrationImpl(
ServiceWorkerDispatcher* dispatcher =
ServiceWorkerDispatcher::GetThreadSpecificInstance();
DCHECK(dispatcher);
+ if (!dispatcher)
+ return;
dispatcher->AddServiceWorkerRegistration(handle_ref_->handle_id(), this);
}

Powered by Google App Engine
This is Rietveld 408576698