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

Unified Diff: content/browser/appcache/appcache_host.cc

Issue 2956373002: Add support for subresource request loads in AppCache for the network service. (Closed)
Patch Set: Address review comments Created 3 years, 5 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/appcache/appcache_host.cc
diff --git a/content/browser/appcache/appcache_host.cc b/content/browser/appcache/appcache_host.cc
index 3af81c5eef57a9a55e8d38147f0ef6ffa3f3d95a..526d72f1ea15d289547b4c5fb1e10fb8d1de534e 100644
--- a/content/browser/appcache/appcache_host.cc
+++ b/content/browser/appcache/appcache_host.cc
@@ -58,7 +58,8 @@ AppCacheHost::AppCacheHost(int host_id, AppCacheFrontend* frontend,
pending_callback_param_(NULL),
main_resource_was_namespace_entry_(false),
main_resource_blocked_(false),
- associated_cache_info_pending_(false) {
+ associated_cache_info_pending_(false),
+ weak_factory_(this) {
service_->AddObserver(this);
}
@@ -543,6 +544,10 @@ void AppCacheHost::CompleteTransfer(int host_id, AppCacheFrontend* frontend) {
frontend_ = frontend;
}
+base::WeakPtr<AppCacheHost> AppCacheHost::GetWeakPtr() {
+ return weak_factory_.GetWeakPtr();
+}
+
void AppCacheHost::AssociateNoCache(const GURL& manifest_url) {
// manifest url can be empty.
AssociateCacheHelper(NULL, manifest_url);

Powered by Google App Engine
This is Rietveld 408576698