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/client/plugin/pepper_port_allocator.h" | 5 #include "remoting/client/plugin/pepper_port_allocator.h" |
6 | 6 |
7 #include "base/bind.h" | 7 #include "base/bind.h" |
8 #include "base/string_number_conversions.h" | 8 #include "base/string_number_conversions.h" |
9 #include "net/base/net_util.h" | 9 #include "net/base/net_util.h" |
10 #include "ppapi/c/pp_errors.h" | 10 #include "ppapi/c/pp_errors.h" |
(...skipping 77 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
88 ice_username_fragment, | 88 ice_username_fragment, |
89 ice_password, | 89 ice_password, |
90 stun_hosts, | 90 stun_hosts, |
91 relay_hosts, | 91 relay_hosts, |
92 relay_token, | 92 relay_token, |
93 std::string()), | 93 std::string()), |
94 instance_(instance), | 94 instance_(instance), |
95 stun_address_resolver_(instance_), | 95 stun_address_resolver_(instance_), |
96 stun_port_(0), | 96 stun_port_(0), |
97 relay_response_received_(false), | 97 relay_response_received_(false), |
98 ALLOW_THIS_IN_INITIALIZER_LIST(weak_factory_(this)) { | 98 weak_factory_(this) { |
99 if (stun_hosts.size() > 0) { | 99 if (stun_hosts.size() > 0) { |
100 stun_address_ = stun_hosts[0]; | 100 stun_address_ = stun_hosts[0]; |
101 } | 101 } |
102 } | 102 } |
103 | 103 |
104 PepperPortAllocatorSession::~PepperPortAllocatorSession() { | 104 PepperPortAllocatorSession::~PepperPortAllocatorSession() { |
105 } | 105 } |
106 | 106 |
107 void PepperPortAllocatorSession::ConfigReady( | 107 void PepperPortAllocatorSession::ConfigReady( |
108 cricket::PortConfiguration* config) { | 108 cricket::PortConfiguration* config) { |
(...skipping 223 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
332 const std::string& content_name, | 332 const std::string& content_name, |
333 int component, | 333 int component, |
334 const std::string& ice_username_fragment, | 334 const std::string& ice_username_fragment, |
335 const std::string& ice_password) { | 335 const std::string& ice_password) { |
336 return new PepperPortAllocatorSession( | 336 return new PepperPortAllocatorSession( |
337 this, content_name, component, ice_username_fragment, ice_password, | 337 this, content_name, component, ice_username_fragment, ice_password, |
338 stun_hosts(), relay_hosts(), relay_token(), instance_); | 338 stun_hosts(), relay_hosts(), relay_token(), instance_); |
339 } | 339 } |
340 | 340 |
341 } // namespace remoting | 341 } // namespace remoting |
OLD | NEW |