summaryrefslogtreecommitdiffstats
path: root/content/browser/browser_main_loop.cc
diff options
context:
space:
mode:
authortoyoshim <toyoshim@chromium.org>2015-07-14 02:42:03 -0700
committerCommit bot <commit-bot@chromium.org>2015-07-14 09:42:41 +0000
commit7c0e19558a837263c1c447a237b699f1fd17c7ee (patch)
treef2f41bdfbcee31089ea5fc04fadbb1e780e538ec /content/browser/browser_main_loop.cc
parent0e6490b1922bab6da94bae0be86f5cabf19e68bb (diff)
downloadchromium_src-7c0e19558a837263c1c447a237b699f1fd17c7ee.zip
chromium_src-7c0e19558a837263c1c447a237b699f1fd17c7ee.tar.gz
chromium_src-7c0e19558a837263c1c447a237b699f1fd17c7ee.tar.bz2
base/threading: restrict to set only current thread priority
On some platforms, e.g., Linux, changing other thread's priority is not permitted by sandbox mechanisms for a security reason. Since there are no real use cases that really need to change another thread's priority for now, I'll replace the base API with the one that change the current thread priority to avoid confusion. BUG=468793,505474 TEST=base_unittests TEST=sudo base_unittests --gtest_filter='Thread*' TEST=git cl try Review URL: https://codereview.chromium.org/1193303002 Cr-Commit-Position: refs/heads/master@{#338661}
Diffstat (limited to 'content/browser/browser_main_loop.cc')
-rw-r--r--content/browser/browser_main_loop.cc3
1 files changed, 1 insertions, 2 deletions
diff --git a/content/browser/browser_main_loop.cc b/content/browser/browser_main_loop.cc
index b0fa2c0..203400e 100644
--- a/content/browser/browser_main_loop.cc
+++ b/content/browser/browser_main_loop.cc
@@ -1108,8 +1108,7 @@ int BrowserMainLoop::BrowserThreadsStarted() {
#if defined(OS_ANDROID)
// Up the priority of the UI thread.
- base::PlatformThread::SetThreadPriority(base::PlatformThread::CurrentHandle(),
- base::ThreadPriority::DISPLAY);
+ base::PlatformThread::SetCurrentThreadPriority(base::ThreadPriority::DISPLAY);
#endif
bool always_uses_gpu = true;