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

Unified Diff: net/base/host_resolver_impl.cc

Issue 6883102: Add one-time randomization support for FieldTrial, and the ability to (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Update comments. Created 9 years, 8 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
Index: net/base/host_resolver_impl.cc
diff --git a/net/base/host_resolver_impl.cc b/net/base/host_resolver_impl.cc
index b512561dca973284c7390feef0900b1bfa03b122..80de5cb3cb5af9ae4d3eb68ee532fdf479a02196 100644
--- a/net/base/host_resolver_impl.cc
+++ b/net/base/host_resolver_impl.cc
@@ -565,9 +565,8 @@ class HostResolverImpl::Job
UMA_HISTOGRAM_ENUMERATION("DNS.ResolveCategory", category, RESOLVE_MAX);
- static bool show_speculative_experiment_histograms =
- base::FieldTrialList::Find("DnsImpact") &&
- !base::FieldTrialList::Find("DnsImpact")->group_name().empty();
+ static const bool show_speculative_experiment_histograms =
+ base::FieldTrialList::TrialExists("DnsImpact");
if (show_speculative_experiment_histograms) {
UMA_HISTOGRAM_ENUMERATION(
base::FieldTrial::MakeName("DNS.ResolveCategory", "DnsImpact"),
@@ -577,9 +576,8 @@ class HostResolverImpl::Job
"DnsImpact"), duration);
}
}
- static bool show_parallelism_experiment_histograms =
- base::FieldTrialList::Find("DnsParallelism") &&
- !base::FieldTrialList::Find("DnsParallelism")->group_name().empty();
+ static const bool show_parallelism_experiment_histograms =
+ base::FieldTrialList::TrialExists("DnsParallelism");
if (show_parallelism_experiment_histograms) {
UMA_HISTOGRAM_ENUMERATION(
base::FieldTrial::MakeName("DNS.ResolveCategory", "DnsParallelism"),

Powered by Google App Engine
This is Rietveld 408576698