summaryrefslogtreecommitdiffstats
path: root/remoting
diff options
context:
space:
mode:
authorthakis@chromium.org <thakis@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2010-11-02 20:15:57 +0000
committerthakis@chromium.org <thakis@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2010-11-02 20:15:57 +0000
commit00cd9c4e71d1e6dd6cc3a2fff60505479304c9d1 (patch)
treeeb61d6402a5e967e5eb1d41dfde730af48dfa55f /remoting
parentd9b888cdf9ad654a3f2e5c22b935e68db77a71ef (diff)
downloadchromium_src-00cd9c4e71d1e6dd6cc3a2fff60505479304c9d1.zip
chromium_src-00cd9c4e71d1e6dd6cc3a2fff60505479304c9d1.tar.gz
chromium_src-00cd9c4e71d1e6dd6cc3a2fff60505479304c9d1.tar.bz2
Convert implicit scoped_refptr constructor calls to explicit ones, part 2
This CL was created automatically by this clang rewriter: http://codereview.appspot.com/2826041 I then did quite a bit of manual editing to fix style issues. BUG=28083 TEST=None Review URL: http://codereview.chromium.org/4291001 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@64798 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'remoting')
-rw-r--r--remoting/base/multiple_array_input_stream.cc3
-rw-r--r--remoting/base/tracer.cc2
-rw-r--r--remoting/protocol/jingle_chromotocol_server.cc2
-rw-r--r--remoting/protocol/message_decoder.cc3
-rw-r--r--remoting/protocol/protocol_test_client.cc4
5 files changed, 8 insertions, 6 deletions
diff --git a/remoting/base/multiple_array_input_stream.cc b/remoting/base/multiple_array_input_stream.cc
index d2127c4..67aa2ff 100644
--- a/remoting/base/multiple_array_input_stream.cc
+++ b/remoting/base/multiple_array_input_stream.cc
@@ -21,7 +21,8 @@ MultipleArrayInputStream::~MultipleArrayInputStream() {
void MultipleArrayInputStream::AddBuffer(net::IOBuffer* buffer, int size) {
DCHECK_EQ(position_, 0); // Haven't started reading.
- buffers_.push_back(new net::DrainableIOBuffer(buffer, size));
+ buffers_.push_back(make_scoped_refptr(
+ new net::DrainableIOBuffer(buffer, size)));
}
bool MultipleArrayInputStream::Next(const void** data, int* size) {
diff --git a/remoting/base/tracer.cc b/remoting/base/tracer.cc
index 4d30f91..3245887 100644
--- a/remoting/base/tracer.cc
+++ b/remoting/base/tracer.cc
@@ -172,7 +172,7 @@ TraceContext::TraceContext() {}
TraceContext::~TraceContext() {}
void TraceContext::PushTracerInternal(Tracer* tracer) {
- tracers_.push_back(tracer);
+ tracers_.push_back(make_scoped_refptr(tracer));
}
void TraceContext::PopTracerInternal() { tracers_.pop_back(); }
diff --git a/remoting/protocol/jingle_chromotocol_server.cc b/remoting/protocol/jingle_chromotocol_server.cc
index 2300243..b0f680b 100644
--- a/remoting/protocol/jingle_chromotocol_server.cc
+++ b/remoting/protocol/jingle_chromotocol_server.cc
@@ -270,7 +270,7 @@ void JingleChromotocolServer::OnSessionCreate(
if (incoming) {
JingleChromotocolConnection* connection =
new JingleChromotocolConnection(this);
- connections_.push_back(connection);
+ connections_.push_back(make_scoped_refptr(connection));
connection->Init(session);
}
}
diff --git a/remoting/protocol/message_decoder.cc b/remoting/protocol/message_decoder.cc
index 4a31ee1..b82eb04 100644
--- a/remoting/protocol/message_decoder.cc
+++ b/remoting/protocol/message_decoder.cc
@@ -22,7 +22,8 @@ MessageDecoder::~MessageDecoder() {}
void MessageDecoder::AddBuffer(scoped_refptr<net::IOBuffer> data,
int data_size) {
- buffer_list_.push_back(new net::DrainableIOBuffer(data, data_size));
+ buffer_list_.push_back(make_scoped_refptr(
+ new net::DrainableIOBuffer(data, data_size)));
available_bytes_ += data_size;
}
diff --git a/remoting/protocol/protocol_test_client.cc b/remoting/protocol/protocol_test_client.cc
index d61c0b5..b28e96d 100644
--- a/remoting/protocol/protocol_test_client.cc
+++ b/remoting/protocol/protocol_test_client.cc
@@ -288,7 +288,7 @@ void ProtocolTestClient::OnStateChange(
host_jid_, CandidateChromotocolConfig::CreateDefault(),
NewCallback(connection,
&ProtocolTestConnection::OnStateChange)));
- connections_.push_back(connection);
+ connections_.push_back(make_scoped_refptr(connection));
}
} else if (state == JingleClient::CLOSED) {
std::cerr << "Connection closed" << std::endl;
@@ -309,7 +309,7 @@ void ProtocolTestClient::OnNewChromotocolConnection(
NewCallback(test_connection, &ProtocolTestConnection::OnStateChange));
test_connection->Init(connection);
AutoLock auto_lock(connections_lock_);
- connections_.push_back(test_connection);
+ connections_.push_back(make_scoped_refptr(test_connection));
}
void ProtocolTestClient::OnFinishedClosing() {