diff -uprN xosview-1.8.3.org/bsd/memmeter.cc xosview-1.8.3.patch1/bsd/memmeter.cc --- xosview-1.8.3.org/bsd/memmeter.cc 2002-07-14 12:48:45.000000000 +0900 +++ xosview-1.8.3.patch1/bsd/memmeter.cc 2012-09-11 23:09:50.000000000 +0900 @@ -107,9 +107,9 @@ void MemMeter::getmeminfo (void) { /* Note that the numbers are in terms of pages, and we want fields_ in bytes. */ int pgsize = kvm_cnt.v_page_size; - fields_[0] = kvm_cnt.v_active_count * pgsize; - fields_[1] = kvm_cnt.v_inactive_count * pgsize; - fields_[2] = kvm_cnt.v_wire_count * pgsize; + fields_[0] = (float)kvm_cnt.v_active_count * pgsize; + fields_[1] = (float)kvm_cnt.v_inactive_count * pgsize; + fields_[2] = (float)kvm_cnt.v_wire_count * pgsize; # ifdef XOSVIEW_FREEBSD /* I believe v_cache_count is the right answer here, rather than the bufspace variable. I think that bufspace is a subset of "cache" space @@ -119,10 +119,10 @@ void MemMeter::getmeminfo (void) { total memory. Perhaps a better representation of what is going on would be to subtract bufspace from v_cache_count, and add that difference to v_inactive_count. (pavel 21-Jan-1998) */ - total_ = fields_[3] = kvm_cnt.v_cache_count * pgsize; + total_ = fields_[3] = (float)kvm_cnt.v_cache_count * pgsize; /*total_ = kvm_cnt.v_page_count * pgsize;*/ # endif /* FreeBSD */ - fields_[FREE_INDEX] = kvm_cnt.v_free_count * pgsize; + fields_[FREE_INDEX] = (float)kvm_cnt.v_free_count * pgsize; #endif /* UVM && NetBSD */ /* Now add to total_ (the cache pages were counted for FreeBSD * above). */