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

Unified Diff: content/browser/resolve_proxy_msg_helper.cc

Issue 10068037: RefCounted types should not have public destructors, content/browser part 1 (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: MSVC fixes Created 8 years, 8 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
« no previous file with comments | « content/browser/resolve_proxy_msg_helper.h ('k') | content/browser/speech/speech_recognizer_impl.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/browser/resolve_proxy_msg_helper.cc
diff --git a/content/browser/resolve_proxy_msg_helper.cc b/content/browser/resolve_proxy_msg_helper.cc
index 65a12a0a446a9149dbb815fbacaa9950bef6e777..c9e6ca1d351b03ec8b85529c5db8c713c2cb3efd 100644
--- a/content/browser/resolve_proxy_msg_helper.cc
+++ b/content/browser/resolve_proxy_msg_helper.cc
@@ -42,6 +42,23 @@ void ResolveProxyMsgHelper::OnResolveProxy(const GURL& url,
StartPendingRequest();
}
+ResolveProxyMsgHelper::~ResolveProxyMsgHelper() {
+ // Clear all pending requests if the ProxyService is still alive (if we have a
+ // default request context or override).
+ if (!pending_requests_.empty()) {
+ PendingRequest req = pending_requests_.front();
+ proxy_service_->CancelPacRequest(req.pac_req);
+ }
+
+ for (PendingRequestList::iterator it = pending_requests_.begin();
+ it != pending_requests_.end();
+ ++it) {
+ delete it->reply_msg;
+ }
+
+ pending_requests_.clear();
+}
+
void ResolveProxyMsgHelper::OnResolveProxyCompleted(int result) {
CHECK(!pending_requests_.empty());
@@ -80,20 +97,3 @@ void ResolveProxyMsgHelper::StartPendingRequest() {
if (result != net::ERR_IO_PENDING)
OnResolveProxyCompleted(result);
}
-
-ResolveProxyMsgHelper::~ResolveProxyMsgHelper() {
- // Clear all pending requests if the ProxyService is still alive (if we have a
- // default request context or override).
- if (!pending_requests_.empty()) {
- PendingRequest req = pending_requests_.front();
- proxy_service_->CancelPacRequest(req.pac_req);
- }
-
- for (PendingRequestList::iterator it = pending_requests_.begin();
- it != pending_requests_.end();
- ++it) {
- delete it->reply_msg;
- }
-
- pending_requests_.clear();
-}
« no previous file with comments | « content/browser/resolve_proxy_msg_helper.h ('k') | content/browser/speech/speech_recognizer_impl.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698