mirror of https://github.com/xzeldon/htop.git
Assume process just started when kproc->ki_start returns garbage
This commit is contained in:
parent
ec809b7f71
commit
1f2f4fe891
|
@ -509,6 +509,9 @@ void ProcessList_goThroughEntries(ProcessList* super, bool pauseProcessUpdate) {
|
||||||
proc->pgrp = kproc->ki_pgid;
|
proc->pgrp = kproc->ki_pgid;
|
||||||
proc->st_uid = kproc->ki_uid;
|
proc->st_uid = kproc->ki_uid;
|
||||||
proc->starttime_ctime = kproc->ki_start.tv_sec;
|
proc->starttime_ctime = kproc->ki_start.tv_sec;
|
||||||
|
if (proc->starttime_ctime < 0) {
|
||||||
|
proc->starttime_ctime = super->realtimeMs / 1000;
|
||||||
|
}
|
||||||
Process_fillStarttimeBuffer(proc);
|
Process_fillStarttimeBuffer(proc);
|
||||||
proc->user = UsersTable_getRef(super->usersTable, proc->st_uid);
|
proc->user = UsersTable_getRef(super->usersTable, proc->st_uid);
|
||||||
ProcessList_add(super, proc);
|
ProcessList_add(super, proc);
|
||||||
|
|
Loading…
Reference in New Issue