| Index: webrtc/modules/congestion_controller/probe_bitrate_estimator.cc
|
| diff --git a/webrtc/modules/congestion_controller/probe_bitrate_estimator.cc b/webrtc/modules/congestion_controller/probe_bitrate_estimator.cc
|
| index 8406387eceb8aaa158d3883594e6a29211be60b0..2d66198ef833744eadf6c4184c00bdbc00b76ef4 100644
|
| --- a/webrtc/modules/congestion_controller/probe_bitrate_estimator.cc
|
| +++ b/webrtc/modules/congestion_controller/probe_bitrate_estimator.cc
|
| @@ -133,10 +133,19 @@ int ProbeBitrateEstimator::HandleProbeAndEstimateBitrate(
|
| << " [receive: " << receive_size << " bytes / "
|
| << receive_interval_ms << " ms = " << receive_bps / 1000
|
| << " kb/s]";
|
| +
|
| float res = std::min(send_bps, receive_bps);
|
| if (event_log_)
|
| event_log_->LogProbeResultSuccess(cluster_id, res);
|
| - return res;
|
| + estimated_bitrate_bps_ = rtc::Optional<int>(std::min(send_bps, res));
|
| + return *estimated_bitrate_bps_;
|
| +}
|
| +
|
| +rtc::Optional<int>
|
| +ProbeBitrateEstimator::FetchAndResetLastEstimatedBitrateBps() {
|
| + rtc::Optional<int> estimated_bitrate_bps = estimated_bitrate_bps_;
|
| + estimated_bitrate_bps_.reset();
|
| + return estimated_bitrate_bps;
|
| }
|
|
|
| void ProbeBitrateEstimator::EraseOldClusters(int64_t timestamp_ms) {
|
|
|