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

Unified Diff: webrtc/api/rtcstatscollector.cc

Issue 2558293002: RTCIceCandidatePairStats.consentRequestsSent set by RTCStatsCollector. (Closed)
Patch Set: requestsSent = pings before first response, consentRequestsSent = pings after first response Created 4 years 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/api/rtcstats_integrationtest.cc ('k') | webrtc/api/rtcstatscollector_unittest.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: webrtc/api/rtcstatscollector.cc
diff --git a/webrtc/api/rtcstatscollector.cc b/webrtc/api/rtcstatscollector.cc
index a7c4cfc577a664a95e83d667d018c9fffc5d20de..9998d9aafe89ed40eb212712adff98caec0cd275 100644
--- a/webrtc/api/rtcstatscollector.cc
+++ b/webrtc/api/rtcstatscollector.cc
@@ -638,12 +638,17 @@ void RTCStatsCollector::ProduceIceCandidateAndPairStats_s(
static_cast<double>(info.rtt) / rtc::kNumMillisecsPerSec;
candidate_pair_stats->requests_received =
static_cast<uint64_t>(info.recv_ping_requests);
- candidate_pair_stats->requests_sent =
- static_cast<uint64_t>(info.sent_ping_requests_total);
+ candidate_pair_stats->requests_sent = static_cast<uint64_t>(
+ info.sent_ping_requests_before_first_response);
candidate_pair_stats->responses_received =
static_cast<uint64_t>(info.recv_ping_responses);
candidate_pair_stats->responses_sent =
static_cast<uint64_t>(info.sent_ping_responses);
+ RTC_DCHECK_GE(info.sent_ping_requests_total,
+ info.sent_ping_requests_before_first_response);
+ candidate_pair_stats->consent_requests_sent = static_cast<uint64_t>(
+ info.sent_ping_requests_total -
+ info.sent_ping_requests_before_first_response);
report->AddStats(std::move(candidate_pair_stats));
}
« no previous file with comments | « webrtc/api/rtcstats_integrationtest.cc ('k') | webrtc/api/rtcstatscollector_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698