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

Unified Diff: content/browser/service_worker/embedded_worker_instance.cc

Issue 282263008: Retry: Stop ServiceWorker context when no controllee is associated (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: leak fix Created 6 years, 7 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 | « no previous file | content/browser/service_worker/embedded_worker_registry.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/browser/service_worker/embedded_worker_instance.cc
diff --git a/content/browser/service_worker/embedded_worker_instance.cc b/content/browser/service_worker/embedded_worker_instance.cc
index 24d2a9529a9843eb6dbf7c36e44efeabd748dd4d..891fc227989ca9cc61b708cd05c2b0be30ed8340 100644
--- a/content/browser/service_worker/embedded_worker_instance.cc
+++ b/content/browser/service_worker/embedded_worker_instance.cc
@@ -22,6 +22,8 @@ struct SecondGreater {
} // namespace
EmbeddedWorkerInstance::~EmbeddedWorkerInstance() {
+ if (status_ == STARTING || status_ == RUNNING)
+ Stop();
registry_->RemoveWorker(process_id_, embedded_worker_id_);
}
« no previous file with comments | « no previous file | content/browser/service_worker/embedded_worker_registry.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698