Make things work on OpenBSD 2.6; this is basically the same than on
2001-02-14 Martin Baulig <baulig@suse.de> * proctime.c (glibtop_get_proc_time_p): Make things work on OpenBSD 2.6; this is basically the same than on NetBSD.
This commit is contained in:
committed by
Martin Baulig
parent
9d772e3c07
commit
0a42a8d018
@@ -1,3 +1,8 @@
|
||||
2001-02-14 Martin Baulig <baulig@suse.de>
|
||||
|
||||
* proctime.c (glibtop_get_proc_time_p): Make things work on
|
||||
OpenBSD 2.6; this is basically the same than on NetBSD.
|
||||
|
||||
2000-02-13 Martin Baulig <martin@home-of-linux.org>
|
||||
|
||||
* *.c: kvm_nlist () returns -1 on error, but a positive return value
|
||||
|
@@ -124,7 +124,7 @@ glibtop_get_proc_time_p (glibtop *server, glibtop_proc_time *buf,
|
||||
pid_t pid)
|
||||
{
|
||||
struct kinfo_proc *pinfo;
|
||||
#if defined(__NetBSD__) && (__NetBSD_Version__ >= 104000000)
|
||||
#if (defined(__NetBSD__) && (__NetBSD_Version__ >= 104000000)) || (defined(OpenBSD) && (OpenBSD >= 199912))
|
||||
register struct rusage *rup;
|
||||
#else
|
||||
struct user *u_addr = (struct user *)USRSTACK;
|
||||
@@ -166,7 +166,7 @@ glibtop_get_proc_time_p (glibtop *server, glibtop_proc_time *buf,
|
||||
buf->frequency = 1000000;
|
||||
buf->flags = _glibtop_sysdeps_proc_time;
|
||||
|
||||
#if defined(__NetBSD__) && (__NetBSD_Version__ >= 104000000)
|
||||
#if (defined(__NetBSD__) && (__NetBSD_Version__ >= 104000000)) || (defined(OpenBSD) && (OpenBSD >= 199912))
|
||||
glibtop_suid_enter (server);
|
||||
|
||||
if (kvm_read (server->machine.kd,
|
||||
|
Reference in New Issue
Block a user