fix swap sizes in FreeBSD, patch by edwin@mavetju.org

2003-10-20  Bastien Nocera  <hadess@hadess.net>

	* swap.c: (glibtop_get_swap_p): fix swap sizes in FreeBSD,
	patch by edwin@mavetju.org
This commit is contained in:
Bastien Nocera
2003-10-20 19:53:57 +00:00
committed by Bastien Nocera
parent 83a3d5f76d
commit 1c96e35cc0
2 changed files with 7 additions and 2 deletions

View File

@@ -1,3 +1,8 @@
2003-10-20 Bastien Nocera <hadess@hadess.net>
* swap.c: (glibtop_get_swap_p): fix swap sizes in FreeBSD,
patch by edwin@mavetju.org
2001-10-17 Abel Cheung <maddog@linux.org.hk> 2001-10-17 Abel Cheung <maddog@linux.org.hk>
* Makefile.am: move header to $(includedir)/libgtop-1.0/glibtop. * Makefile.am: move header to $(includedir)/libgtop-1.0/glibtop.

View File

@@ -369,8 +369,8 @@ glibtop_get_swap_p (glibtop *server, glibtop_swap *buf)
buf->flags = _glibtop_sysdeps_swap; buf->flags = _glibtop_sysdeps_swap;
buf->used = kvmsw[nswdev].ksw_used; buf->used = kvmsw[nswdev].ksw_used * getpagesize();
buf->total = kvmsw[nswdev].ksw_total; buf->total = kvmsw[nswdev].ksw_total * getpagesize();
buf->free = buf->total - buf->used; buf->free = buf->total - buf->used;