Improved freebsd port.

Patch by Joe Marcus Clarke <marcus@freebsd.org>.
Closes #548184.

svn path=/trunk/; revision=2767
This commit is contained in:
Benoît Dejean
2008-08-18 16:11:07 +00:00
parent 10e5124770
commit 10a04fc9c7
10 changed files with 545 additions and 11 deletions

View File

@@ -25,6 +25,7 @@
#include <glibtop/shm_limits.h>
#include <sys/types.h>
#include <sys/param.h>
#include <sys/sysctl.h>
static unsigned long _glibtop_sysdeps_shm_limits =
@@ -46,7 +47,11 @@ void
glibtop_get_shm_limits_s (glibtop *server, glibtop_shm_limits *buf)
{
size_t len;
#if __FreeBSD_version < 700002
int shmmax, shmmin, shmmni, shmseg, shmall;
#else
unsigned long shmmax, shmmin, shmmni, shmseg, shmall;
#endif
glibtop_init_s (&server, GLIBTOP_SYSDEPS_SHM_LIMITS, 0);