| OLD | NEW |
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #include "remoting/protocol/pepper_transport_factory.h" | 5 #include "remoting/protocol/pepper_transport_factory.h" |
| 6 | 6 |
| 7 #include "base/bind.h" | 7 #include "base/bind.h" |
| 8 #include "crypto/hmac.h" | 8 #include "crypto/hmac.h" |
| 9 #include "jingle/glue/utils.h" | 9 #include "jingle/glue/utils.h" |
| 10 #include "net/base/cert_status_flags.h" | 10 #include "net/base/cert_status_flags.h" |
| (...skipping 236 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 247 NotifyConnectFailed(); | 247 NotifyConnectFailed(); |
| 248 return; | 248 return; |
| 249 } | 249 } |
| 250 | 250 |
| 251 NotifyConnected(socket.Pass()); | 251 NotifyConnected(socket.Pass()); |
| 252 } | 252 } |
| 253 | 253 |
| 254 void PepperStreamTransport::NotifyConnected( | 254 void PepperStreamTransport::NotifyConnected( |
| 255 scoped_ptr<net::StreamSocket> socket) { | 255 scoped_ptr<net::StreamSocket> socket) { |
| 256 DCHECK(!connected_); | 256 DCHECK(!connected_); |
| 257 connected_ = true; |
| 257 callback_.Run(socket.Pass()); | 258 callback_.Run(socket.Pass()); |
| 258 connected_ = true; | |
| 259 } | 259 } |
| 260 | 260 |
| 261 void PepperStreamTransport::NotifyConnectFailed() { | 261 void PepperStreamTransport::NotifyConnectFailed() { |
| 262 channel_ = NULL; | 262 channel_ = NULL; |
| 263 owned_channel_.reset(); | 263 owned_channel_.reset(); |
| 264 authenticator_.reset(); | 264 authenticator_.reset(); |
| 265 | 265 |
| 266 NotifyConnected(scoped_ptr<net::StreamSocket>(NULL)); | 266 NotifyConnected(scoped_ptr<net::StreamSocket>(NULL)); |
| 267 } | 267 } |
| 268 | 268 |
| (...skipping 12 matching lines...) Expand all Loading... |
| 281 } | 281 } |
| 282 | 282 |
| 283 scoped_ptr<DatagramTransport> | 283 scoped_ptr<DatagramTransport> |
| 284 PepperTransportFactory::CreateDatagramTransport() { | 284 PepperTransportFactory::CreateDatagramTransport() { |
| 285 NOTIMPLEMENTED(); | 285 NOTIMPLEMENTED(); |
| 286 return scoped_ptr<DatagramTransport>(NULL); | 286 return scoped_ptr<DatagramTransport>(NULL); |
| 287 } | 287 } |
| 288 | 288 |
| 289 } // namespace protocol | 289 } // namespace protocol |
| 290 } // namespace remoting | 290 } // namespace remoting |
| OLD | NEW |