OLD | NEW |
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #include "base/metrics/field_trial.h" | 5 #include "base/metrics/field_trial.h" |
6 | 6 |
7 #include <algorithm> | 7 #include <algorithm> |
8 | 8 |
9 #include "base/build_time.h" | 9 #include "base/build_time.h" |
10 #include "base/logging.h" | 10 #include "base/logging.h" |
11 #include "base/rand_util.h" | 11 #include "base/rand_util.h" |
12 #include "base/sha1.h" | |
13 #include "base/strings/string_util.h" | 12 #include "base/strings/string_util.h" |
14 #include "base/strings/stringprintf.h" | 13 #include "base/strings/stringprintf.h" |
15 #include "base/strings/utf_string_conversions.h" | 14 #include "base/strings/utf_string_conversions.h" |
16 | 15 |
17 namespace base { | 16 namespace base { |
18 | 17 |
19 namespace { | 18 namespace { |
20 | 19 |
21 // Created a time value based on |year|, |month| and |day_of_month| parameters. | 20 // Created a time value based on |year|, |month| and |day_of_month| parameters. |
22 Time CreateTimeFromParams(int year, int month, int day_of_month) { | 21 Time CreateTimeFromParams(int year, int month, int day_of_month) { |
(...skipping 571 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
594 return; | 593 return; |
595 } | 594 } |
596 AutoLock auto_lock(global_->lock_); | 595 AutoLock auto_lock(global_->lock_); |
597 DCHECK(!global_->PreLockedFind(trial->trial_name())); | 596 DCHECK(!global_->PreLockedFind(trial->trial_name())); |
598 trial->AddRef(); | 597 trial->AddRef(); |
599 trial->SetTrialRegistered(); | 598 trial->SetTrialRegistered(); |
600 global_->registered_[trial->trial_name()] = trial; | 599 global_->registered_[trial->trial_name()] = trial; |
601 } | 600 } |
602 | 601 |
603 } // namespace base | 602 } // namespace base |
OLD | NEW |