Linux: fix display of new thread for one cycle when hidden

This commit is contained in:
Christian Göttsche 2020-11-23 14:44:31 +01:00
parent 003f2c06a4
commit 6c2849ec81
1 changed files with 3 additions and 2 deletions

View File

@ -1047,8 +1047,6 @@ static bool LinuxProcessList_recurseProcTree(LinuxProcessList* this, const char*
continue;
}
proc->show = true;
#ifdef HAVE_TASKSTATS
if (settings->flags & PROCESS_FLAG_IO)
LinuxProcessList_readIoFile(lp, dirname, name, now);
@ -1167,6 +1165,9 @@ static bool LinuxProcessList_recurseProcTree(LinuxProcessList* this, const char*
}
}
/* Set at the end when we know if a new entry is a thread */
proc->show = ! ((hideKernelThreads && Process_isKernelThread(proc)) || (hideUserlandThreads && Process_isUserlandThread(proc)));
pl->totalTasks++;
if (proc->state == 'R')
pl->runningTasks++;