summaryrefslogtreecommitdiffstats
path: root/content/child/service_worker
diff options
context:
space:
mode:
authorxiang.long <xiang.long@intel.com>2015-02-03 23:04:57 -0800
committerCommit bot <commit-bot@chromium.org>2015-02-04 07:05:50 +0000
commitafc4f16f4cf1b894cef3c35b806d32ef644ae3b5 (patch)
tree3575d38076d045f0b2f5da7da3c9d56056dac0d5 /content/child/service_worker
parentd15575438ed0a945770625e4a7b1ccaa7754ad6a (diff)
downloadchromium_src-afc4f16f4cf1b894cef3c35b806d32ef644ae3b5.zip
chromium_src-afc4f16f4cf1b894cef3c35b806d32ef644ae3b5.tar.gz
chromium_src-afc4f16f4cf1b894cef3c35b806d32ef644ae3b5.tar.bz2
ServiceWorker: add ServiceWorkerClients.claim() support (2/3).
The claiming registration will fetch all registrations from DB and comparing them with existing provider hosts. If it has the longest match, it will start controlling the provider host. Spec: https://slightlyoff.github.io/ServiceWorker/spec/service_worker/#clients-claim (1/3): https://codereview.chromium.org/868463004/ (2/3): This (3/3): https://codereview.chromium.org/872593002/ BUG=450106 TEST=https://codereview.chromium.org/872593002/ Review URL: https://codereview.chromium.org/871853002 Cr-Commit-Position: refs/heads/master@{#314514}
Diffstat (limited to 'content/child/service_worker')
-rw-r--r--content/child/service_worker/service_worker_dispatcher.cc2
1 files changed, 1 insertions, 1 deletions
diff --git a/content/child/service_worker/service_worker_dispatcher.cc b/content/child/service_worker/service_worker_dispatcher.cc
index 99230db..73b9a29 100644
--- a/content/child/service_worker/service_worker_dispatcher.cc
+++ b/content/child/service_worker/service_worker_dispatcher.cc
@@ -346,11 +346,11 @@ void ServiceWorkerDispatcher::OnDisassociateRegistration(
ProviderContextMap::iterator provider = provider_contexts_.find(provider_id);
if (provider == provider_contexts_.end())
return;
- provider->second->OnDisassociateRegistration();
worker_to_provider_.erase(provider->second->installing_handle_id());
worker_to_provider_.erase(provider->second->waiting_handle_id());
worker_to_provider_.erase(provider->second->active_handle_id());
worker_to_provider_.erase(provider->second->controller_handle_id());
+ provider->second->OnDisassociateRegistration();
}
void ServiceWorkerDispatcher::OnRegistered(