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

Unified Diff: chrome/browser/safe_browsing/safe_browsing_service.cc

Issue 3951001: Use scoped_refptr for refcounted param in SafeBrowsingService. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 10 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
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/safe_browsing/safe_browsing_service.cc
diff --git a/chrome/browser/safe_browsing/safe_browsing_service.cc b/chrome/browser/safe_browsing/safe_browsing_service.cc
index 5448f9389a12818275b29ead5393016d5743b893..781d7613de88457bd90b437d953c4aca07bc7bdb 100644
--- a/chrome/browser/safe_browsing/safe_browsing_service.cc
+++ b/chrome/browser/safe_browsing/safe_browsing_service.cc
@@ -386,9 +386,6 @@ void SafeBrowsingService::OnIOInitialize(
mackey_url_prefix,
disable_auto_update);
- // Balance the reference added by Start().
- request_context_getter->Release();
-
protocol_manager_->Initialize();
}
@@ -648,9 +645,8 @@ void SafeBrowsingService::Start() {
}
// We will issue network fetches using the default profile's request context.
- URLRequestContextGetter* request_context_getter =
+ scoped_refptr<URLRequestContextGetter> request_context_getter =
GetDefaultProfile()->GetRequestContext();
- request_context_getter->AddRef(); // Balanced in OnIOInitialize.
BrowserThread::PostTask(
BrowserThread::IO, FROM_HERE,
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698