From 9fb9ea1c03de2336693b7a817125db4716887837 Mon Sep 17 00:00:00 2001 From: Andriy Gapon Date: Sat, 6 Oct 2012 20:12:24 +0000 Subject: [PATCH] kvm_proclist: ignore processes in larvae state Reviewed by: jhb MFC after: 8 days --- lib/libkvm/kvm_proc.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/lib/libkvm/kvm_proc.c b/lib/libkvm/kvm_proc.c index 8fc415c5e8f0..d1daf77ef8f3 100644 --- a/lib/libkvm/kvm_proc.c +++ b/lib/libkvm/kvm_proc.c @@ -144,6 +144,8 @@ kvm_proclist(kvm_t *kd, int what, int arg, struct proc *p, _kvm_err(kd, kd->program, "can't read proc at %p", p); return (-1); } + if (proc.p_state == PRS_NEW) + continue; if (proc.p_state != PRS_ZOMBIE) { if (KREAD(kd, (u_long)TAILQ_FIRST(&proc.p_threads), &mtd)) {