| Index: base/tracked_objects.cc
|
| diff --git a/base/tracked_objects.cc b/base/tracked_objects.cc
|
| index d24cedf159241d58a92909650de374f187dd85ae..ef8bfcd93efa3a61a29bf0921ff293cad5cb8ca5 100644
|
| --- a/base/tracked_objects.cc
|
| +++ b/base/tracked_objects.cc
|
| @@ -355,7 +355,7 @@ ThreadData* ThreadData::next() const { return next_; }
|
|
|
| // static
|
| void ThreadData::InitializeThreadContext(const std::string& suggested_name) {
|
| - Initialize();
|
| + EnsureTlsInitialization();
|
| ThreadData* current_thread_data =
|
| reinterpret_cast<ThreadData*>(tls_index_.Get());
|
| if (current_thread_data)
|
| @@ -669,7 +669,7 @@ void ThreadData::OnProfilingPhaseCompletedOnThread(int profiling_phase) {
|
| }
|
| }
|
|
|
| -void ThreadData::Initialize() {
|
| +void ThreadData::EnsureTlsInitialization() {
|
| if (base::subtle::Acquire_Load(&status_) >= DEACTIVATED)
|
| return; // Someone else did the initialization.
|
| // Due to racy lazy initialization in tests, we'll need to recheck status_
|
| @@ -709,7 +709,7 @@ void ThreadData::InitializeAndSetTrackingStatus(Status status) {
|
| DCHECK_GE(status, DEACTIVATED);
|
| DCHECK_LE(status, PROFILING_ACTIVE);
|
|
|
| - Initialize(); // No-op if already initialized.
|
| + EnsureTlsInitialization(); // No-op if already initialized.
|
|
|
| if (status > DEACTIVATED)
|
| status = PROFILING_ACTIVE;
|
|
|