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

Unified Diff: base/process_linux.cc

Issue 8989035: CheckForNicePermission: Make sure can_reraise_priority is set in ctor (Closed) Base URL: http://git.chromium.org/chromium/src.git@master
Patch Set: move data to the bottom of the struct Created 9 years 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 | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: base/process_linux.cc
diff --git a/base/process_linux.cc b/base/process_linux.cc
index cb413e153b6d02cbeb36d0bbe7745f118a21e001..9f69596dcb4a5f05fcac48cf3395f75bb6f0f49d 100644
--- a/base/process_linux.cc
+++ b/base/process_linux.cc
@@ -107,9 +107,7 @@ bool Process::SetProcessBackgrounded(bool background) {
}
struct CheckForNicePermission {
- bool can_reraise_priority;
-
- CheckForNicePermission() {
+ CheckForNicePermission() : can_reraise_priority(false) {
// We won't be able to raise the priority if we don't have the right rlimit.
// The limit may be adjusted in /etc/security/limits.conf for PAM systems.
struct rlimit rlim;
@@ -118,6 +116,8 @@ struct CheckForNicePermission {
can_reraise_priority = true;
}
};
+
+ bool can_reraise_priority;
};
// static
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698