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

Unified Diff: content/browser/service_worker/service_worker_dispatcher_host.h

Issue 2506263005: Prevent a service worker from keeping itself alive by self postMessage. (Closed)
Patch Set: rebase Created 4 years 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/browser/service_worker/service_worker_dispatcher_host.h
diff --git a/content/browser/service_worker/service_worker_dispatcher_host.h b/content/browser/service_worker/service_worker_dispatcher_host.h
index 08c5698c48f1bccae2d712c24663c58f4fc37f75..ae1e55116f142889633be889b7ea02b60b343163 100644
--- a/content/browser/service_worker/service_worker_dispatcher_host.h
+++ b/content/browser/service_worker/service_worker_dispatcher_host.h
@@ -13,6 +13,7 @@
#include "base/id_map.h"
#include "base/macros.h"
#include "base/memory/weak_ptr.h"
+#include "base/optional.h"
#include "base/strings/string16.h"
#include "content/browser/service_worker/service_worker_registration_status.h"
#include "content/common/service_worker/service_worker.mojom.h"
@@ -188,6 +189,7 @@ class CONTENT_EXPORT ServiceWorkerDispatcherHost
const base::string16& message,
const url::Origin& source_origin,
const std::vector<int>& sent_message_ports,
+ const base::Optional<base::TimeDelta>& timeout,
const StatusCallback& callback,
const SourceInfo& source_info);
void DispatchExtendableMessageEventAfterStartWorker(
@@ -196,6 +198,7 @@ class CONTENT_EXPORT ServiceWorkerDispatcherHost
const url::Origin& source_origin,
const std::vector<int>& sent_message_ports,
const ExtendableMessageEventSource& source,
+ const base::Optional<base::TimeDelta>& timeout,
const StatusCallback& callback);
template <typename SourceInfo>
void DidFailToDispatchExtendableMessageEvent(

Powered by Google App Engine
This is Rietveld 408576698