summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorIvan Kozik <ivan@ludios.org>2016-09-06 09:22:38 +0000
committerGitHub <noreply@github.com>2016-09-06 09:22:38 +0000
commit07086fcf776833e9e2a7ad7f8bd6c1a5481d0d00 (patch)
treebe9b37537097391095002e28d55d59138fddb857
parent6d4df3d138cefc3312235f451620f342cc97a136 (diff)
Fix column misalignment for priority -101 threads
BFS-patched kernels can have kernel threads with priority -101. This change makes priority -101 display as "RT", just like priority -100. Related: https://github.com/hishamhm/htop/issues/314
-rw-r--r--Process.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/Process.c b/Process.c
index 8e2abb6a..6a904e2c 100644
--- a/Process.c
+++ b/Process.c
@@ -429,7 +429,7 @@ void Process_writeField(Process* this, RichString* str, ProcessField field) {
case PID: snprintf(buffer, n, Process_pidFormat, this->pid); break;
case PPID: snprintf(buffer, n, Process_pidFormat, this->ppid); break;
case PRIORITY: {
- if(this->priority == -100)
+ if(this->priority <= -100)
snprintf(buffer, n, " RT ");
else
snprintf(buffer, n, "%3ld ", this->priority);

© 2014-2024 Faster IT GmbH | imprint | privacy policy