Using correct (1 << GLIBTOP_SYSDPES_*)'. Removed
const' from sysctl ()
1998-08-24 Martin Baulig <martin@home-of-linux.org> * *.c (glibtop_init_p): Using correct `(1 << GLIBTOP_SYSDPES_*)'. * cpu.c, mem.c: Removed `const' from sysctl () constants to keep compiler happy. * procmem.c: Added missing call to `glibtop_init_p'. * prockernel.c: Casting `nwchan' to `unsigned long' since this normally has the same size than a pointer. Well, is there a FreeBSD for 64bit architectures ?
This commit is contained in:
committed by
Martin Baulig
parent
b41bcfdfb1
commit
a894d550a1
@@ -37,8 +37,8 @@ static struct nlist nlst [] = {
|
||||
};
|
||||
|
||||
/* MIB array for sysctl */
|
||||
static const int mib_length=2;
|
||||
static const int mib [] = { CTL_KERN, KERN_CLOCKRATE };
|
||||
static int mib_length=2;
|
||||
static int mib [] = { CTL_KERN, KERN_CLOCKRATE };
|
||||
|
||||
/* Init function. */
|
||||
|
||||
@@ -61,7 +61,7 @@ glibtop_get_cpu_p (glibtop *server, glibtop_cpu *buf)
|
||||
struct clockinfo ci;
|
||||
size_t length;
|
||||
|
||||
glibtop_init_p (server, GLIBTOP_SYSDEPS_CPU, 0);
|
||||
glibtop_init_p (server, (1 << GLIBTOP_SYSDEPS_CPU), 0);
|
||||
|
||||
memset (buf, 0, sizeof (glibtop_cpu));
|
||||
|
||||
|
Reference in New Issue
Block a user