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

Unified Diff: webrtc/call/call.cc

Issue 2125523004: Fix bug where a connection switch causes BWE to be set to zero. (Closed) Base URL: https://chromium.googlesource.com/external/webrtc.git@master
Patch Set: Comments addressed. Created 4 years, 5 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 | « no previous file | webrtc/video/video_send_stream_tests.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: webrtc/call/call.cc
diff --git a/webrtc/call/call.cc b/webrtc/call/call.cc
index c85eaf6990b8ceb1a8a9a0f17fe6ca8b19064c68..dfb1879a5fdae4acb63dbc7bc167e3f28a364da2 100644
--- a/webrtc/call/call.cc
+++ b/webrtc/call/call.cc
@@ -579,7 +579,12 @@ void Call::SetBitrateConfig(
// Nothing new to set, early abort to avoid encoder reconfigurations.
return;
}
- config_.bitrate_config = bitrate_config;
+ config_.bitrate_config.min_bitrate_bps = bitrate_config.min_bitrate_bps;
+ // Start bitrate of -1 means we should keep the old bitrate, which there is
+ // no point in remembering for the future.
+ if (bitrate_config.start_bitrate_bps > 0)
+ config_.bitrate_config.start_bitrate_bps = bitrate_config.start_bitrate_bps;
+ config_.bitrate_config.max_bitrate_bps = bitrate_config.max_bitrate_bps;
congestion_controller_->SetBweBitrates(bitrate_config.min_bitrate_bps,
bitrate_config.start_bitrate_bps,
bitrate_config.max_bitrate_bps);
« no previous file with comments | « no previous file | webrtc/video/video_send_stream_tests.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698