Index: chromecast/base/metrics/cast_metrics_helper.cc |
diff --git a/chromecast/base/metrics/cast_metrics_helper.cc b/chromecast/base/metrics/cast_metrics_helper.cc |
index 9a6cdfd3051b76b663ba7509af4f1e408b1ad454..89c3d008e33aa92012aff2d329d7f7050cf24fb2 100644 |
--- a/chromecast/base/metrics/cast_metrics_helper.cc |
+++ b/chromecast/base/metrics/cast_metrics_helper.cc |
@@ -54,8 +54,9 @@ bool CastMetricsHelper::DecodeAppInfoFromMetricsName( |
if (metrics_name.find(kMetricsNameAppInfoDelimiter) == std::string::npos) |
return false; |
- std::vector<std::string> tokens; |
- base::SplitString(metrics_name, kMetricsNameAppInfoDelimiter, &tokens); |
+ std::vector<std::string> tokens = base::SplitString( |
+ metrics_name, std::string(1, kMetricsNameAppInfoDelimiter), |
+ base::TRIM_WHITESPACE, base::SPLIT_WANT_ALL); |
DCHECK_EQ(tokens.size(), 4u); |
// The order of tokens should match EncodeAppInfoIntoMetricsName(). |
*action_name = tokens[0]; |