Do not update stats for WebRTC.Call.EstimatedSendBitrateInKbps if we are not sending video.
This hopefully fixes a UMA stats regression introduced in 71ee44cc6d
BUG=webrtc:6244
TBR=stefan@webrtc.org
Review URL: https://codereview.webrtc.org/2274713002 .
Cr-Commit-Position: refs/heads/master@{#13868}
This commit is contained in:
parent
b37c45cadc
commit
5bed20f7c6
@ -735,6 +735,12 @@ void Call::OnNetworkChanged(uint32_t target_bitrate_bps, uint8_t fraction_loss,
|
||||
// Ignore updates where the bitrate is zero because the aggregate network
|
||||
// state is down.
|
||||
if (target_bitrate_bps > 0) {
|
||||
{
|
||||
ReadLockScoped read_lock(*send_crit_);
|
||||
// Do not update the stats if we are not sending video.
|
||||
if (video_send_streams_.empty())
|
||||
return;
|
||||
}
|
||||
rtc::CritScope lock(&bitrate_crit_);
|
||||
// We only update these stats if we have send streams, and assume that
|
||||
// OnNetworkChanged is called roughly with a fixed frequency.
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user