| Index: base/threading/platform_thread_win.cc
|
| diff --git a/base/threading/platform_thread_win.cc b/base/threading/platform_thread_win.cc
|
| index 4eb2cb2b33d38004952060a1658b02382e733818..b9f7a5648ad3ff2350e12e728a28a7158f75bac3 100644
|
| --- a/base/threading/platform_thread_win.cc
|
| +++ b/base/threading/platform_thread_win.cc
|
| @@ -154,7 +154,7 @@ void PlatformThread::Sleep(TimeDelta duration) {
|
| }
|
|
|
| // static
|
| -void PlatformThread::SetName(const std::string& name) {
|
| +void PlatformThread::SetName(const char* name) {
|
| ThreadIdNameManager::GetInstance()->SetName(CurrentId(), name);
|
|
|
| // On Windows only, we don't need to tell the profiler about the "BrokerEvent"
|
| @@ -163,7 +163,7 @@ void PlatformThread::SetName(const std::string& name) {
|
| // which would also (as a side effect) initialize the profiler in this unused
|
| // context, including setting up thread local storage, etc. The performance
|
| // impact is not terrible, but there is no reason to do initialize it.
|
| - if (name != "BrokerEvent")
|
| + if (0 != strcmp(name, "BrokerEvent"))
|
| tracked_objects::ThreadData::InitializeThreadContext(name);
|
|
|
| // The debugger needs to be around to catch the name in the exception. If
|
| @@ -173,7 +173,7 @@ void PlatformThread::SetName(const std::string& name) {
|
| if (!::IsDebuggerPresent() && !base::debug::IsBinaryInstrumented())
|
| return;
|
|
|
| - SetNameInternal(CurrentId(), name.c_str());
|
| + SetNameInternal(CurrentId(), name);
|
| }
|
|
|
| // static
|
|
|