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

Unified Diff: chrome/browser/net/connection_tester.cc

Issue 4192012: Convert implicit scoped_refptr constructor calls to explicit ones, part 1 (Closed) Base URL: http://git.chromium.org/git/chromium.git
Patch Set: fix presubmit 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 | « chrome/browser/metrics/metrics_service.cc ('k') | chrome/browser/net/connection_tester_unittest.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/net/connection_tester.cc
diff --git a/chrome/browser/net/connection_tester.cc b/chrome/browser/net/connection_tester.cc
index 889494d28d4209871ee9fc9dbccc2d6c4baf712c..8f762ef881e8d34ad7b137ee2d4a75318466e049 100644
--- a/chrome/browser/net/connection_tester.cc
+++ b/chrome/browser/net/connection_tester.cc
@@ -277,8 +277,8 @@ void ConnectionTester::TestRunner::OnReadCompleted(URLRequest* request,
void ConnectionTester::TestRunner::ReadBody(URLRequest* request) {
// Read the response body |kReadBufferSize| bytes at a time.
- scoped_refptr<net::IOBuffer> unused_buffer =
- new net::IOBuffer(kReadBufferSize);
+ scoped_refptr<net::IOBuffer> unused_buffer(
+ new net::IOBuffer(kReadBufferSize));
int num_bytes;
if (request->Read(unused_buffer, kReadBufferSize, &num_bytes)) {
OnReadCompleted(request, num_bytes);
@@ -299,8 +299,8 @@ void ConnectionTester::TestRunner::OnResponseCompleted(URLRequest* request) {
void ConnectionTester::TestRunner::Run(const Experiment& experiment) {
// Try to create a URLRequestContext for this experiment.
- scoped_refptr<ExperimentURLRequestContext> context =
- new ExperimentURLRequestContext(tester_->io_thread_);
+ scoped_refptr<ExperimentURLRequestContext> context(
+ new ExperimentURLRequestContext(tester_->io_thread_));
int rv = context->Init(experiment);
if (rv != net::OK) {
// Complete the experiment with a failure.
« no previous file with comments | « chrome/browser/metrics/metrics_service.cc ('k') | chrome/browser/net/connection_tester_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698