From owner-cvs-src@FreeBSD.ORG Mon Mar 21 16:36:05 2005 Return-Path: Delivered-To: cvs-src@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id D9D6616A4CE; Mon, 21 Mar 2005 16:36:05 +0000 (GMT) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id C16B943D1F; Mon, 21 Mar 2005 16:36:05 +0000 (GMT) (envelope-from keramida@FreeBSD.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.1/8.13.1) with ESMTP id j2LGa5Ij054702; Mon, 21 Mar 2005 16:36:05 GMT (envelope-from keramida@repoman.freebsd.org) Received: (from keramida@localhost) by repoman.freebsd.org (8.13.1/8.13.1/Submit) id j2LGa5Xx054701; Mon, 21 Mar 2005 16:36:05 GMT (envelope-from keramida) Message-Id: <200503211636.j2LGa5Xx054701@repoman.freebsd.org> From: Giorgos Keramidas Date: Mon, 21 Mar 2005 16:36:05 +0000 (UTC) To: src-committers@FreeBSD.org, cvs-src@FreeBSD.org, cvs-all@FreeBSD.org X-FreeBSD-CVS-Branch: HEAD Subject: cvs commit: src/usr.sbin/pstat Makefile pstat.8 pstat.c X-BeenThere: cvs-src@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: CVS commit messages for the src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 21 Mar 2005 16:36:06 -0000 keramida 2005-03-21 16:36:05 UTC FreeBSD src repository (doc committer) Modified files: usr.sbin/pstat Makefile pstat.8 pstat.c Log: - Add a -h flag to pstat to print swap sizes in "human readable" format, with humanize_number(3). - Move the common parts of the code that prints the sizes for a single swap device and the total to a single function to avoid repeating the humanize_number() stuff all over the place. - Change the type of CONVERT() from intmax_t to int64_t, since this makes calling humanize_number() easier but cast the values to intmax_t before printing them, to make use of the %jd format that printf() supports. - Document the new -h flag in the manpage and bump its date. Approved by: pjd Useful tips: brooks MFC after: 2 weeks Revision Changes Path 1.13 +2 -2 src/usr.sbin/pstat/Makefile 1.47 +8 -3 src/usr.sbin/pstat/pstat.8 1.93 +40 -19 src/usr.sbin/pstat/pstat.c