summaryrefslogtreecommitdiffstats
path: root/chrome
diff options
context:
space:
mode:
Diffstat (limited to 'chrome')
-rw-r--r--chrome/browser/browser_main.cc9
-rw-r--r--chrome/gpu/gpu_main.cc3
-rw-r--r--chrome/nacl/nacl_main.cc11
-rw-r--r--chrome/plugin/plugin_main.cc3
-rw-r--r--chrome/profile_import/profile_import_main.cc4
-rw-r--r--chrome/renderer/renderer_main.cc3
-rw-r--r--chrome/service/service_main.cc3
-rw-r--r--chrome/utility/utility_main.cc3
-rw-r--r--chrome/worker/worker_main.cc3
9 files changed, 12 insertions, 30 deletions
diff --git a/chrome/browser/browser_main.cc b/chrome/browser/browser_main.cc
index bd37e7d..fa58807 100644
--- a/chrome/browser/browser_main.cc
+++ b/chrome/browser/browser_main.cc
@@ -823,12 +823,9 @@ int BrowserMain(const MainFunctionParams& parameters) {
SystemMonitor system_monitor;
HighResolutionTimerManager hi_res_timer_manager;
- std::wstring app_name = chrome::kBrowserAppName;
- std::string thread_name_string = WideToASCII(app_name + L"_BrowserMain");
-
- const char* thread_name = thread_name_string.c_str();
- PlatformThread::SetName(thread_name);
- main_message_loop.set_thread_name(thread_name);
+ const char* kThreadName = "CrBrowserMain";
+ PlatformThread::SetName(kThreadName);
+ main_message_loop.set_thread_name(kThreadName);
// Register the main thread by instantiating it, but don't call any methods.
ChromeThread main_thread(ChromeThread::UI, MessageLoop::current());
diff --git a/chrome/gpu/gpu_main.cc b/chrome/gpu/gpu_main.cc
index 86652e5..c6c4aee 100644
--- a/chrome/gpu/gpu_main.cc
+++ b/chrome/gpu/gpu_main.cc
@@ -35,8 +35,7 @@ int GpuMain(const MainFunctionParams& parameters) {
}
MessageLoop main_message_loop(MessageLoop::TYPE_UI);
- std::wstring app_name = chrome::kBrowserAppName;
- PlatformThread::SetName(WideToASCII(app_name + L"_GpuMain").c_str());
+ PlatformThread::SetName("CrGpuMain");
#if defined(OS_WIN)
win_util::ScopedCOMInitializer com_initializer;
diff --git a/chrome/nacl/nacl_main.cc b/chrome/nacl/nacl_main.cc
index 4dc2691..760eb85 100644
--- a/chrome/nacl/nacl_main.cc
+++ b/chrome/nacl/nacl_main.cc
@@ -34,8 +34,7 @@
int NaClBrokerMain(const MainFunctionParams& parameters) {
// The main thread of the broker.
MessageLoopForIO main_message_loop;
- std::wstring app_name = chrome::kNaClAppName;
- PlatformThread::SetName(WideToASCII(app_name + L"_NaClBrokerMain").c_str());
+ PlatformThread::SetName("CrNaClBrokerMain");
SystemMonitor system_monitor;
HighResolutionTimerManager hi_res_timer_manager;
@@ -122,13 +121,7 @@ int NaClMain(const MainFunctionParams& parameters) {
// The main thread of the plugin services IO.
MessageLoopForIO main_message_loop;
- // NaCl code runs in a different binary on Win64.
-#ifdef _WIN64
- std::wstring app_name = chrome::kNaClAppName;
-#else
- std::wstring app_name = chrome::kBrowserAppName;
-#endif
- PlatformThread::SetName(WideToASCII(app_name + L"_NaClMain").c_str());
+ PlatformThread::SetName("CrNaClMain");
SystemMonitor system_monitor;
HighResolutionTimerManager hi_res_timer_manager;
diff --git a/chrome/plugin/plugin_main.cc b/chrome/plugin/plugin_main.cc
index f2da7e3..eccdc27 100644
--- a/chrome/plugin/plugin_main.cc
+++ b/chrome/plugin/plugin_main.cc
@@ -60,8 +60,7 @@ int PluginMain(const MainFunctionParams& parameters) {
InitializeChromeApplication();
#endif
MessageLoop main_message_loop(MessageLoop::TYPE_UI);
- std::wstring app_name = chrome::kBrowserAppName;
- PlatformThread::SetName(WideToASCII(app_name + L"_PluginMain").c_str());
+ PlatformThread::SetName("CrPluginMain");
SystemMonitor system_monitor;
HighResolutionTimerManager high_resolution_timer_manager;
diff --git a/chrome/profile_import/profile_import_main.cc b/chrome/profile_import/profile_import_main.cc
index 546df18..ced62d5 100644
--- a/chrome/profile_import/profile_import_main.cc
+++ b/chrome/profile_import/profile_import_main.cc
@@ -16,9 +16,7 @@
int ProfileImportMain(const MainFunctionParams& parameters) {
// The main message loop of the profile import process.
MessageLoop main_message_loop;
- std::wstring app_name = chrome::kBrowserAppName;
- PlatformThread::SetName(WideToASCII(
- app_name + L"_ProfileImportMain").c_str());
+ PlatformThread::SetName("CrProfileImportMain");
ChildProcess profile_import_process;
profile_import_process.set_main_thread(new ProfileImportThread());
diff --git a/chrome/renderer/renderer_main.cc b/chrome/renderer/renderer_main.cc
index 1f77d3e..f521e11 100644
--- a/chrome/renderer/renderer_main.cc
+++ b/chrome/renderer/renderer_main.cc
@@ -236,8 +236,7 @@ int RendererMain(const MainFunctionParams& parameters) {
MessageLoop::TYPE_UI : MessageLoop::TYPE_DEFAULT);
#endif
- std::wstring app_name = chrome::kBrowserAppName;
- PlatformThread::SetName(WideToASCII(app_name + L"_RendererMain").c_str());
+ PlatformThread::SetName("CrRendererMain");
SystemMonitor system_monitor;
HighResolutionTimerManager hi_res_timer_manager;
diff --git a/chrome/service/service_main.cc b/chrome/service/service_main.cc
index 8fea68d..35c869b 100644
--- a/chrome/service/service_main.cc
+++ b/chrome/service/service_main.cc
@@ -15,8 +15,7 @@
// Mainline routine for running as the service process.
int ServiceProcessMain(const MainFunctionParams& parameters) {
MessageLoopForUI main_message_loop;
- std::wstring app_name = chrome::kBrowserAppName;
- PlatformThread::SetName(WideToASCII(app_name + L"_ServiceMain").c_str());
+ PlatformThread::SetName("CrServiceMain");
ServiceProcess service_process;
service_process.Initialize();
diff --git a/chrome/utility/utility_main.cc b/chrome/utility/utility_main.cc
index 690d47b1..a568566 100644
--- a/chrome/utility/utility_main.cc
+++ b/chrome/utility/utility_main.cc
@@ -25,8 +25,7 @@
int UtilityMain(const MainFunctionParams& parameters) {
// The main message loop of the utility process.
MessageLoop main_message_loop;
- std::wstring app_name = chrome::kBrowserAppName;
- PlatformThread::SetName(WideToASCII(app_name + L"_UtilityMain").c_str());
+ PlatformThread::SetName("CrUtilityMain");
SystemMonitor system_monitor;
HighResolutionTimerManager hi_res_timer_manager;
diff --git a/chrome/worker/worker_main.cc b/chrome/worker/worker_main.cc
index 86b352b..d839760 100644
--- a/chrome/worker/worker_main.cc
+++ b/chrome/worker/worker_main.cc
@@ -23,8 +23,7 @@
int WorkerMain(const MainFunctionParams& parameters) {
// The main message loop of the worker process.
MessageLoop main_message_loop;
- std::wstring app_name = chrome::kBrowserAppName;
- PlatformThread::SetName(WideToASCII(app_name + L"_WorkerMain").c_str());
+ PlatformThread::SetName("CrWorkerMain");
SystemMonitor system_monitor;
HighResolutionTimerManager hi_res_timer_manager;