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

Unified Diff: content/renderer/media/mock_peer_connection_impl.cc

Issue 385613003: Fix an issue with an upcoming webrtc roll where the 'name' property of StatsReport::Value is const. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Pick a more future proof value name Created 6 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 | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/renderer/media/mock_peer_connection_impl.cc
diff --git a/content/renderer/media/mock_peer_connection_impl.cc b/content/renderer/media/mock_peer_connection_impl.cc
index 41fa2d1a5d5895fa68b8d0d9cff825378e120201..380670f9db304ac19b60689d1da0a5c850fb9b53 100644
--- a/content/renderer/media/mock_peer_connection_impl.cc
+++ b/content/renderer/media/mock_peer_connection_impl.cc
@@ -274,9 +274,10 @@ bool MockPeerConnectionImpl::GetStats(
report.id = "1234";
report.type = "ssrc";
report.timestamp = 42;
- webrtc::StatsReport::Value value;
- value.name = "trackname";
- value.value = "trackvalue";
+ webrtc::StatsReport::Value value = {
+ webrtc::StatsReport::kStatsValueNameFingerprint,
+ "trackvalue"
+ };
report.values.push_back(value);
// If selector is given, we pass back one report.
// If selector is not given, we pass back two.
@@ -286,9 +287,11 @@ bool MockPeerConnectionImpl::GetStats(
report2.type = "generic";
report2.timestamp = 44;
report2.values.push_back(value);
- value.name = "somename";
- value.value = "somevalue";
- report2.values.push_back(value);
+ webrtc::StatsReport::Value value2 = {
+ webrtc::StatsReport::kStatsValueNameFingerprintAlgorithm,
+ "somevalue"
+ };
+ report2.values.push_back(value2);
}
// Note that the callback is synchronous, not asynchronous; it will
// happen before the request call completes.
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698