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

Side by Side Diff: chrome/browser/safe_browsing/ping_manager.cc

Issue 2230203002: chrome: Use stl utilities from the base namespace (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Removed accidental components/ change Created 4 years, 4 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 unified diff | Download patch
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 "chrome/browser/safe_browsing/ping_manager.h" 5 #include "chrome/browser/safe_browsing/ping_manager.h"
6 6
7 #include <utility> 7 #include <utility>
8 8
9 #include "base/logging.h" 9 #include "base/logging.h"
10 #include "base/memory/ptr_util.h" 10 #include "base/memory/ptr_util.h"
(...skipping 57 matching lines...) Expand 10 before | Expand all | Expand 10 after
68 68
69 permission_reporter_.reset( 69 permission_reporter_.reset(
70 new PermissionReporter(request_context_getter->GetURLRequestContext())); 70 new PermissionReporter(request_context_getter->GetURLRequestContext()));
71 } 71 }
72 72
73 version_ = SafeBrowsingProtocolManagerHelper::Version(); 73 version_ = SafeBrowsingProtocolManagerHelper::Version();
74 } 74 }
75 75
76 SafeBrowsingPingManager::~SafeBrowsingPingManager() { 76 SafeBrowsingPingManager::~SafeBrowsingPingManager() {
77 // Delete in-progress safebrowsing reports (hits and details). 77 // Delete in-progress safebrowsing reports (hits and details).
78 STLDeleteContainerPointers(safebrowsing_reports_.begin(), 78 base::STLDeleteContainerPointers(safebrowsing_reports_.begin(),
79 safebrowsing_reports_.end()); 79 safebrowsing_reports_.end());
80 } 80 }
81 81
82 // net::URLFetcherDelegate implementation ---------------------------------- 82 // net::URLFetcherDelegate implementation ----------------------------------
83 83
84 // All SafeBrowsing request responses are handled here. 84 // All SafeBrowsing request responses are handled here.
85 void SafeBrowsingPingManager::OnURLFetchComplete( 85 void SafeBrowsingPingManager::OnURLFetchComplete(
86 const net::URLFetcher* source) { 86 const net::URLFetcher* source) {
87 Reports::iterator sit = safebrowsing_reports_.find(source); 87 Reports::iterator sit = safebrowsing_reports_.find(source);
88 DCHECK(sit != safebrowsing_reports_.end()); 88 DCHECK(sit != safebrowsing_reports_.end());
89 delete *sit; 89 delete *sit;
(...skipping 145 matching lines...) Expand 10 before | Expand all | Expand 10 after
235 version_.c_str()); 235 version_.c_str());
236 std::string api_key = google_apis::GetAPIKey(); 236 std::string api_key = google_apis::GetAPIKey();
237 if (!api_key.empty()) { 237 if (!api_key.empty()) {
238 base::StringAppendF(&url, "&key=%s", 238 base::StringAppendF(&url, "&key=%s",
239 net::EscapeQueryParamValue(api_key, true).c_str()); 239 net::EscapeQueryParamValue(api_key, true).c_str());
240 } 240 }
241 return GURL(url); 241 return GURL(url);
242 } 242 }
243 243
244 } // namespace safe_browsing 244 } // namespace safe_browsing
OLDNEW
« no previous file with comments | « chrome/browser/safe_browsing/local_database_manager.cc ('k') | chrome/browser/safe_browsing/protocol_manager.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698