Subject: Question about kvm_getproc2()
To: None <tech-kern@netbsd.org>
From: Daniel Sieger <dsieger@TechFak.Uni-Bielefeld.DE>
List: tech-kern
Date: 01/02/2007 16:01:20
--IJpNTDwzlM2Ie8A6
Content-Type: text/plain; charset=us-ascii
Content-Disposition: inline
Content-Transfer-Encoding: quoted-printable

Hi all,
I stumbled upon something strange in our kvm_getproc2() function. I don't
know if there is any rationale behind this, but the following lines
do not seem correct to me. From src/lib/libkvm/kvm_proc.c, lines 555 and
556:

	kp2p->p_rtime_sec =3D kp->kp_proc.p_estcpu;
	kp2p->p_rtime_usec =3D kp->kp_proc.p_estcpu;

Shouldn't this be=20

	kp2p->p_rtime_sec =3D kp->kp_proc.p_rtime.tv_sec;
	kp2p->p_rtime_usec =3D kp->kp_proc.p_rtime.tv_usec;

Please enlighten me if the current code is correct and I just don't=20
get it. ;-)

Regards,
Daniel

--=20
Daniel Sieger
Faculty of Technology
Bielefeld University
wwwhomes.uni-bielefeld.de/dsieger

--IJpNTDwzlM2Ie8A6
Content-Type: application/pgp-signature
Content-Disposition: inline

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.2.4 (SunOS)

iD8DBQFFmnO/JUKmeYzbnToRAoGOAJ4wWmfp+wDBfhJLpzOUxn4QOCCJDQCgivKe
FfERhUzgvrPNoDFbacSzn2Y=
=6HI0
-----END PGP SIGNATURE-----

--IJpNTDwzlM2Ie8A6--