summaryrefslogtreecommitdiff
path: root/Applications/ProcessManager
diff options
context:
space:
mode:
authorAndreas Kling <awesomekling@gmail.com>2019-04-20 19:41:57 +0200
committerAndreas Kling <awesomekling@gmail.com>2019-04-20 19:41:57 +0200
commit180de7e8c5ba2d4c4517cf923c98c943c95c2295 (patch)
treec2725529194ee32a65b893e4cd7f55e1fa8aac46 /Applications/ProcessManager
parentde913529d7c7c76ba78dbbf0d2bfd1dae5a96437 (diff)
downloadserenity-180de7e8c5ba2d4c4517cf923c98c943c95c2295.zip
ProcessManager: Exclude colonel process from process listing.
Diffstat (limited to 'Applications/ProcessManager')
-rw-r--r--Applications/ProcessManager/ProcessModel.cpp6
1 files changed, 3 insertions, 3 deletions
diff --git a/Applications/ProcessManager/ProcessModel.cpp b/Applications/ProcessManager/ProcessModel.cpp
index cbd19e64d2..eae0ce0ead 100644
--- a/Applications/ProcessManager/ProcessModel.cpp
+++ b/Applications/ProcessManager/ProcessModel.cpp
@@ -23,7 +23,7 @@ ProcessModel::~ProcessModel()
int ProcessModel::row_count(const GModelIndex&) const
{
- return m_processes.size();
+ return m_pids.size();
}
int ProcessModel::column_count(const GModelIndex&) const
@@ -203,11 +203,11 @@ void ProcessModel::update()
pids_to_remove.append(it.key);
continue;
}
-
auto& process = *it.value;
dword nsched_diff = process.current_state.nsched - process.previous_state.nsched;
process.current_state.cpu_percent = ((float)nsched_diff * 100) / (float)(sum_nsched - last_sum_nsched);
- m_pids.append(it.key);
+ if (it.key != 0)
+ m_pids.append(it.key);
}
for (auto pid : pids_to_remove)
m_processes.remove(pid);