From d879ff5bb8ccc0d3419f5bbdc5caed26adfaf138 Mon Sep 17 00:00:00 2001 From: Doug MacEachern Date: Wed, 9 Feb 2005 03:56:27 +0000 Subject: [PATCH] rename handle to /dev/kmem --- src/os/darwin/darwin_sigar.c | 8 ++++---- src/os/darwin/sigar_os.h | 2 +- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/src/os/darwin/darwin_sigar.c b/src/os/darwin/darwin_sigar.c index b2651b94..d1799189 100644 --- a/src/os/darwin/darwin_sigar.c +++ b/src/os/darwin/darwin_sigar.c @@ -41,7 +41,7 @@ static int get_koffsets(sigar_t *sigar) { NULL } }; - kvm_nlist(sigar->kp, klist); + kvm_nlist(sigar->kmem, klist); if (klist[0].n_type == 0) { return errno; } @@ -61,7 +61,7 @@ static int kread(sigar_t *sigar, void *data, int size, long offset) } #endif - if (kvm_read(sigar->kp, offset, data, size) != size) { + if (kvm_read(sigar->kmem, offset, data, size) != size) { return errno; } @@ -95,7 +95,7 @@ int sigar_os_open(sigar_t **sigar) #ifdef DARWIN (*sigar)->mach_port = mach_host_self(); #else - (*sigar)->kp = kvm_open(NULL, NULL, NULL, O_RDONLY, "kvm_open"); + (*sigar)->kmem = kvm_open(NULL, NULL, NULL, O_RDONLY, "kvm_open"); #endif get_koffsets(*sigar); @@ -238,7 +238,7 @@ int sigar_swap_get(sigar_t *sigar, sigar_swap_t *swap) #else struct kvm_swap kswap[1]; - if (kvm_getswapinfo(sigar->kp, kswap, 1, 0) < 0) { + if (kvm_getswapinfo(sigar->kmem, kswap, 1, 0) < 0) { return errno; } diff --git a/src/os/darwin/sigar_os.h b/src/os/darwin/sigar_os.h index 5f886178..18222e8b 100644 --- a/src/os/darwin/sigar_os.h +++ b/src/os/darwin/sigar_os.h @@ -24,7 +24,7 @@ struct sigar_t { #ifdef DARWIN mach_port_t mach_port; #else - kvm_t *kp; + kvm_t *kmem; /* offsets for seeking on kmem */ unsigned long koffsets[KOFFSET_MAX]; #endif