Index: content/browser/renderer_host/p2p/socket_host_tcp.cc |
diff --git a/content/browser/renderer_host/p2p/socket_host_tcp.cc b/content/browser/renderer_host/p2p/socket_host_tcp.cc |
index 623086d0ba4d33755137e017154bcfe6669921db..954fb49f5e8587f24491f00d2ce10ed3bb09e0d1 100644 |
--- a/content/browser/renderer_host/p2p/socket_host_tcp.cc |
+++ b/content/browser/renderer_host/p2p/socket_host_tcp.cc |
@@ -67,14 +67,15 @@ P2PSocketHostTcpBase::~P2PSocketHostTcpBase() { |
} |
} |
-bool P2PSocketHostTcpBase::InitAccepted(const net::IPEndPoint& remote_address, |
- net::StreamSocket* socket) { |
- DCHECK(socket); |
+bool P2PSocketHostTcpBase::InitAccepted( |
+ const net::IPEndPoint& remote_address, |
+ std::unique_ptr<net::StreamSocket> socket) { |
+ DCHECK(socket.get()); |
Sergey Ulanov
2016/08/15 16:54:59
nit: don't need .get() here
Avi (use Gerrit)
2016/08/15 18:10:29
Done.
|
DCHECK_EQ(state_, STATE_UNINITIALIZED); |
remote_address_.ip_address = remote_address; |
// TODO(ronghuawu): Add FakeSSLServerSocket. |
- socket_.reset(socket); |
+ socket_ = std::move(socket); |
state_ = STATE_OPEN; |
DoRead(); |
return state_ != STATE_ERROR; |
@@ -444,8 +445,10 @@ void P2PSocketHostTcpBase::HandleWriteResult(int result) { |
} |
} |
-P2PSocketHost* P2PSocketHostTcpBase::AcceptIncomingTcpConnection( |
- const net::IPEndPoint& remote_address, int id) { |
+std::unique_ptr<P2PSocketHost> |
+P2PSocketHostTcpBase::AcceptIncomingTcpConnection( |
+ const net::IPEndPoint& remote_address, |
+ int id) { |
NOTREACHED(); |
OnError(); |
return NULL; |