SCCS-vsn: usr.bin/netstat/mbuf.c 4.3
-static char sccsid[] = "@(#)mbuf.c 4.2 82/12/05";
+static char sccsid[] = "@(#)mbuf.c 4.3 82/12/06";
#endif
#include <sys/param.h>
#endif
#include <sys/param.h>
totmem = mbstat.m_mbufs * MSIZE + mbstat.m_clusters * CLBYTES;
totfree = mbstat.m_mbfree * MSIZE + mbstat.m_clusters * CLBYTES;
printf("\t%dKbytes allocated to network (%d%% in use)\n",
totmem = mbstat.m_mbufs * MSIZE + mbstat.m_clusters * CLBYTES;
totfree = mbstat.m_mbfree * MSIZE + mbstat.m_clusters * CLBYTES;
printf("\t%dKbytes allocated to network (%d%% in use)\n",
- totmem / 1024,
- (totmem - totfree + totmem - 1) / totmem);
+ totmem / 1024, (totmem - totfree) * 100 / totmem);