fix Darwin side of SIGAR-47: integer multlipcation overflow on 32bit builds with more than 4GB available memory

This commit is contained in:
Kay Röpke authored and Doug MacEachern committed 2009-06-01 13:05:58 -07:00
1 parent a04e2db66f
commit 596bc2a522
1 file changed
+2 -1
+2 -1
View File
@@ -460,7 +460,8 @@ int sigar_mem_get(sigar_t *sigar, sigar_mem_t *mem)
return status;
}
mem->free = vmstat.free_count * sigar->pagesize;
mem->free = vmstat.free_count;
mem->free =* sigar->pagesize;
#elif defined(__FreeBSD__)
if ((status = sigar_vmstat(sigar, &vmstat)) == SIGAR_OK) {
mem->free = vmstat.v_free_count;