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

Unified Diff: webrtc/pc/channel.cc

Issue 1972493002: Do not create a temporary transport channel when using max-bundle (Closed) Base URL: https://chromium.googlesource.com/external/webrtc.git@master
Patch Set: Rebase Created 4 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 | « webrtc/pc/channel.h ('k') | webrtc/pc/channel_unittest.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: webrtc/pc/channel.cc
diff --git a/webrtc/pc/channel.cc b/webrtc/pc/channel.cc
index 7a0d1efaff7da13bcc8d5119a63a201fedf70af1..97c1d6691014ff3b79951607d72458de61aa4fa6 100644
--- a/webrtc/pc/channel.cc
+++ b/webrtc/pc/channel.cc
@@ -229,8 +229,9 @@ void BaseChannel::DestroyTransportChannels_n() {
network_thread_->Clear(this);
}
-bool BaseChannel::Init_w() {
- if (!network_thread_->Invoke<bool>(Bind(&BaseChannel::InitNetwork_n, this))) {
+bool BaseChannel::Init_w(const std::string* bundle_transport_name) {
+ if (!network_thread_->Invoke<bool>(
+ Bind(&BaseChannel::InitNetwork_n, this, bundle_transport_name))) {
return false;
}
@@ -241,9 +242,11 @@ bool BaseChannel::Init_w() {
return true;
}
-bool BaseChannel::InitNetwork_n() {
+bool BaseChannel::InitNetwork_n(const std::string* bundle_transport_name) {
RTC_DCHECK(network_thread_->IsCurrent());
- if (!SetTransport_n(content_name())) {
+ const std::string& transport_name =
+ (bundle_transport_name ? *bundle_transport_name : content_name());
+ if (!SetTransport_n(transport_name)) {
return false;
}
@@ -1476,8 +1479,8 @@ VoiceChannel::~VoiceChannel() {
Deinit();
}
-bool VoiceChannel::Init_w() {
- if (!BaseChannel::Init_w()) {
+bool VoiceChannel::Init_w(const std::string* bundle_transport_name) {
+ if (!BaseChannel::Init_w(bundle_transport_name)) {
return false;
}
return true;
@@ -1831,8 +1834,8 @@ VideoChannel::VideoChannel(rtc::Thread* worker_thread,
content_name,
rtcp) {}
-bool VideoChannel::Init_w() {
- if (!BaseChannel::Init_w()) {
+bool VideoChannel::Init_w(const std::string* bundle_transport_name) {
+ if (!BaseChannel::Init_w(bundle_transport_name)) {
return false;
}
return true;
@@ -2103,8 +2106,8 @@ DataChannel::~DataChannel() {
Deinit();
}
-bool DataChannel::Init_w() {
- if (!BaseChannel::Init_w()) {
+bool DataChannel::Init_w(const std::string* bundle_transport_name) {
+ if (!BaseChannel::Init_w(bundle_transport_name)) {
return false;
}
media_channel()->SignalDataReceived.connect(
« no previous file with comments | « webrtc/pc/channel.h ('k') | webrtc/pc/channel_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698