summaryrefslogtreecommitdiffstats
path: root/remoting/client
diff options
context:
space:
mode:
authorsergeyu@chromium.org <sergeyu@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2013-12-16 20:09:34 +0000
committersergeyu@chromium.org <sergeyu@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2013-12-16 20:09:34 +0000
commita4564bbdff060a3b9d1793ba0b01b4dfb0684826 (patch)
tree76d1b35bd3ad260a1b673846d5b27e5fc32ceec9 /remoting/client
parent487209b9298d131be927809d88e42a9e598ece80 (diff)
downloadchromium_src-a4564bbdff060a3b9d1793ba0b01b4dfb0684826.zip
chromium_src-a4564bbdff060a3b9d1793ba0b01b4dfb0684826.tar.gz
chromium_src-a4564bbdff060a3b9d1793ba0b01b4dfb0684826.tar.bz2
Fix LibjingleTransportFactory to refresh STUN/Relay.
Previously chromoting host would get relay info only when started. Relay token expires within several hours, which means relay session creation would always fail from the host running for longer than several hours, and that makes connection impossible in some configurations. Moved code that gets Jingle info to LibjingleTransportFactory and it's responsible for refreshing relay token every hour. BUG=318897 R=rmsousa@chromium.org Committed: https://src.chromium.org/viewvc/chrome?view=rev&revision=240926 Review URL: https://codereview.chromium.org/98173006 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@240997 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'remoting/client')
-rw-r--r--remoting/client/jni/chromoting_jni_instance.cc4
-rw-r--r--remoting/client/plugin/chromoting_instance.cc4
2 files changed, 6 insertions, 2 deletions
diff --git a/remoting/client/jni/chromoting_jni_instance.cc b/remoting/client/jni/chromoting_jni_instance.cc
index 339cea8..641fcd8 100644
--- a/remoting/client/jni/chromoting_jni_instance.cc
+++ b/remoting/client/jni/chromoting_jni_instance.cc
@@ -309,7 +309,9 @@ void ChromotingJniInstance::ConnectToHostOnNetworkThread() {
scoped_ptr<protocol::TransportFactory> transport_factory(
new protocol::LibjingleTransportFactory(
- port_allocator.PassAs<cricket::HttpPortAllocatorBase>(), false));
+ signaling_.get(),
+ port_allocator.PassAs<cricket::HttpPortAllocatorBase>(),
+ network_settings));
client_->Start(signaling_.get(), transport_factory.Pass());
}
diff --git a/remoting/client/plugin/chromoting_instance.cc b/remoting/client/plugin/chromoting_instance.cc
index ba69267..46e30f5 100644
--- a/remoting/client/plugin/chromoting_instance.cc
+++ b/remoting/client/plugin/chromoting_instance.cc
@@ -658,7 +658,9 @@ void ChromotingInstance::ConnectWithConfig(const ClientConfig& config,
scoped_ptr<cricket::HttpPortAllocatorBase> port_allocator(
PepperPortAllocator::Create(this));
scoped_ptr<protocol::TransportFactory> transport_factory(
- new protocol::LibjingleTransportFactory(port_allocator.Pass(), false));
+ new protocol::LibjingleTransportFactory(
+ signal_strategy_.get(), port_allocator.Pass(),
+ NetworkSettings(NetworkSettings::NAT_TRAVERSAL_ENABLED)));
// Kick off the connection.
client_->Start(signal_strategy_.get(), transport_factory.Pass());