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

Unified Diff: remoting/protocol/message_reader.cc

Issue 15782010: Update remoting/ and jingle/ to use scoped_refptr<T>::get() rather than implicit "operator T*" (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 7 years, 7 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 | « remoting/protocol/message_decoder.cc ('k') | remoting/protocol/negotiating_authenticator_unittest.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: remoting/protocol/message_reader.cc
diff --git a/remoting/protocol/message_reader.cc b/remoting/protocol/message_reader.cc
index 7f999d5401e238ad0546d9cffa391b90cadba31b..8312109240f994829c5584de9e976865ab08c970 100644
--- a/remoting/protocol/message_reader.cc
+++ b/remoting/protocol/message_reader.cc
@@ -48,7 +48,8 @@ void MessageReader::DoRead() {
while (!closed_ && !read_pending_ && pending_messages_ == 0) {
read_buffer_ = new net::IOBuffer(kReadBufferSize);
int result = socket_->Read(
- read_buffer_, kReadBufferSize,
+ read_buffer_.get(),
+ kReadBufferSize,
base::Bind(&MessageReader::OnRead, weak_factory_.GetWeakPtr()));
HandleReadResult(result);
}
@@ -71,7 +72,7 @@ void MessageReader::HandleReadResult(int result) {
return;
if (result > 0) {
- OnDataReceived(read_buffer_, result);
+ OnDataReceived(read_buffer_.get(), result);
} else if (result == net::ERR_IO_PENDING) {
read_pending_ = true;
} else {
« no previous file with comments | « remoting/protocol/message_decoder.cc ('k') | remoting/protocol/negotiating_authenticator_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698