Let Call register ReceiveSideCongestionController as CallStatsObserver.
Fixes a regression from cl https://codereview.webrtc.org/2752233002.
BUG=chromium:704491,webrtc:6847
Review-Url: https://codereview.webrtc.org/2777423002
Cr-Commit-Position: refs/heads/master@{#17407}
diff --git a/webrtc/call/call.cc b/webrtc/call/call.cc
index ef3bc85..94acc9f 100644
--- a/webrtc/call/call.cc
+++ b/webrtc/call/call.cc
@@ -392,6 +392,7 @@
config_.bitrate_config.min_bitrate_bps,
config_.bitrate_config.start_bitrate_bps,
config_.bitrate_config.max_bitrate_bps);
+ call_stats_->RegisterStatsObserver(&receive_side_cc_);
call_stats_->RegisterStatsObserver(transport_send_->send_side_cc());
module_process_thread_->Start();
@@ -426,6 +427,7 @@
module_process_thread_->DeRegisterModule(&receive_side_cc_);
module_process_thread_->DeRegisterModule(call_stats_.get());
module_process_thread_->Stop();
+ call_stats_->DeregisterStatsObserver(&receive_side_cc_);
call_stats_->DeregisterStatsObserver(transport_send_->send_side_cc());
// Only update histograms after process threads have been shut down, so that
diff --git a/webrtc/modules/congestion_controller/include/receive_side_congestion_controller.h b/webrtc/modules/congestion_controller/include/receive_side_congestion_controller.h
index f6f9462..1d205b5 100644
--- a/webrtc/modules/congestion_controller/include/receive_side_congestion_controller.h
+++ b/webrtc/modules/congestion_controller/include/receive_side_congestion_controller.h
@@ -46,7 +46,6 @@
virtual const RemoteBitrateEstimator* GetRemoteBitrateEstimator(
bool send_side_bwe) const;
- // TODO(nisse): Called by CongestionController, but not otherwise wired up.
// Implements CallStatsObserver.
void OnRttUpdate(int64_t avg_rtt_ms, int64_t max_rtt_ms) override;