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

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

Issue 625433002: Pages controlled by ServiceWorkers should not participate in AppCaching (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 6 years, 2 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/browser/service_worker/service_worker_request_handler.h
diff --git a/content/browser/service_worker/service_worker_request_handler.h b/content/browser/service_worker/service_worker_request_handler.h
index 64090bfef9c537f7773388fd73215da6bbafa671..2042adcf95f08312c5488202176a62d340c829df 100644
--- a/content/browser/service_worker/service_worker_request_handler.h
+++ b/content/browser/service_worker/service_worker_request_handler.h
@@ -67,6 +67,12 @@ class CONTENT_EXPORT ServiceWorkerRequestHandler
// Creates a protocol interceptor for ServiceWorker.
static scoped_ptr<net::URLRequestInterceptor> CreateInterceptor();
+ // Returns true if the request falls into the scope of a ServiceWorker.
+ // It's only reliable after the ServiceWorkerRequestHandler MaybeCreateJob
+ // method run to completion for this request. The AppCache handler uses
falken 2014/10/14 01:24:49 nit: runs
+ // this to avoid colliding with ServiceWorkers.
+ static bool IsControlledByServiceWorker(net::URLRequest* request);
+
virtual ~ServiceWorkerRequestHandler();
// Called via custom URLRequestJobFactory.

Powered by Google App Engine
This is Rietveld 408576698