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

Unified Diff: base/metrics/field_trial_param_associator.cc

Issue 2560823002: TSAN startup fix (Closed)
Patch Set: 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 | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: base/metrics/field_trial_param_associator.cc
diff --git a/base/metrics/field_trial_param_associator.cc b/base/metrics/field_trial_param_associator.cc
index 0230b8a8a8d39082d166052eb00303e4ff03919e..4a4e361b5d51318fde718940ee07413874d18974 100644
--- a/base/metrics/field_trial_param_associator.cc
+++ b/base/metrics/field_trial_param_associator.cc
@@ -21,11 +21,10 @@ bool FieldTrialParamAssociator::AssociateFieldTrialParams(
const std::string& trial_name,
const std::string& group_name,
const FieldTrialParams& params) {
- AutoLock scoped_lock(lock_);
-
if (FieldTrialList::IsTrialActive(trial_name))
return false;
+ AutoLock scoped_lock(lock_);
const FieldTrialKey key(trial_name, group_name);
if (ContainsKey(field_trial_params_, key))
return false;
« 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