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

Side by Side Diff: content/browser/appcache/appcache_quota_client.cc

Issue 2478573004: Convert GURL::{host,path} to GURL::{host_piece,path_piece} for ==. (Closed)
Patch Set: rebase to #431874 Created 4 years, 1 month 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 unified diff | Download patch
« no previous file with comments | « components/url_formatter/url_formatter.cc ('k') | content/browser/frame_host/debug_urls.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "content/browser/appcache/appcache_quota_client.h" 5 #include "content/browser/appcache/appcache_quota_client.h"
6 6
7 #include <algorithm> 7 #include <algorithm>
8 #include <map> 8 #include <map>
9 #include <set> 9 #include <set>
10 10
(...skipping 166 matching lines...) Expand 10 before | Expand all | Expand 10 after
177 177
178 if (type != storage::kStorageTypeTemporary) { 178 if (type != storage::kStorageTypeTemporary) {
179 callback.Run(std::set<GURL>()); 179 callback.Run(std::set<GURL>());
180 return; 180 return;
181 } 181 }
182 182
183 const AppCacheStorage::UsageMap* map = GetUsageMap(); 183 const AppCacheStorage::UsageMap* map = GetUsageMap();
184 std::set<GURL> origins; 184 std::set<GURL> origins;
185 for (AppCacheStorage::UsageMap::const_iterator iter = map->begin(); 185 for (AppCacheStorage::UsageMap::const_iterator iter = map->begin();
186 iter != map->end(); ++iter) { 186 iter != map->end(); ++iter) {
187 if (opt_host.empty() || iter->first.host() == opt_host) 187 if (opt_host.empty() || iter->first.host_piece() == opt_host)
188 origins.insert(iter->first); 188 origins.insert(iter->first);
189 } 189 }
190 callback.Run(origins); 190 callback.Run(origins);
191 } 191 }
192 192
193 void AppCacheQuotaClient::ProcessPendingRequests() { 193 void AppCacheQuotaClient::ProcessPendingRequests() {
194 DCHECK(appcache_is_ready_); 194 DCHECK(appcache_is_ready_);
195 while (!pending_batch_requests_.empty()) 195 while (!pending_batch_requests_.empty())
196 RunFront(&pending_batch_requests_); 196 RunFront(&pending_batch_requests_);
197 197
(...skipping 44 matching lines...) Expand 10 before | Expand all | Expand 10 after
242 current_delete_request_callback_.Run(storage::kQuotaErrorAbort); 242 current_delete_request_callback_.Run(storage::kQuotaErrorAbort);
243 current_delete_request_callback_.Reset(); 243 current_delete_request_callback_.Reset();
244 GetServiceDeleteCallback()->Cancel(); 244 GetServiceDeleteCallback()->Cancel();
245 } 245 }
246 246
247 if (quota_manager_is_destroyed_) 247 if (quota_manager_is_destroyed_)
248 delete this; 248 delete this;
249 } 249 }
250 250
251 } // namespace content 251 } // namespace content
OLDNEW
« no previous file with comments | « components/url_formatter/url_formatter.cc ('k') | content/browser/frame_host/debug_urls.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698