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

Unified Diff: base/threading/platform_thread_android.cc

Issue 1128733002: Update from https://crrev.com/328418 (Closed) Base URL: git@github.com:domokit/mojo.git@master
Patch Set: Created 5 years, 7 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
« no previous file with comments | « base/threading/platform_thread.h ('k') | base/threading/platform_thread_freebsd.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: base/threading/platform_thread_android.cc
diff --git a/base/threading/platform_thread_android.cc b/base/threading/platform_thread_android.cc
index a31f65918fe621849d980dadd75ba8c63237fd15..11e5e2e3c870d25d79d205e7dcd349239a02eac2 100644
--- a/base/threading/platform_thread_android.cc
+++ b/base/threading/platform_thread_android.cc
@@ -64,7 +64,7 @@ bool GetThreadPriorityForPlatform(PlatformThreadHandle handle,
} // namespace internal
-void PlatformThread::SetName(const char* name) {
+void PlatformThread::SetName(const std::string& name) {
ThreadIdNameManager::GetInstance()->SetName(CurrentId(), name);
tracked_objects::ThreadData::InitializeThreadContext(name);
@@ -76,7 +76,7 @@ void PlatformThread::SetName(const char* name) {
return;
// Set the name for the LWP (which gets truncated to 15 characters).
- int err = prctl(PR_SET_NAME, name);
+ int err = prctl(PR_SET_NAME, name.c_str());
if (err < 0 && errno != EPERM)
DPLOG(ERROR) << "prctl(PR_SET_NAME)";
}
« no previous file with comments | « base/threading/platform_thread.h ('k') | base/threading/platform_thread_freebsd.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698