From owner-cvs-all@FreeBSD.ORG Tue Jan 22 11:18:52 2008 Return-Path: Delivered-To: cvs-all@FreeBSD.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 8559716A421; Tue, 22 Jan 2008 11:18:52 +0000 (UTC) (envelope-from keramida@FreeBSD.org) Received: from repoman.freebsd.org (repoman.freebsd.org [IPv6:2001:4f8:fff6::29]) by mx1.freebsd.org (Postfix) with ESMTP id 407DB13C46E; Tue, 22 Jan 2008 11:18:52 +0000 (UTC) (envelope-from keramida@FreeBSD.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.14.1/8.14.1) with ESMTP id m0MBIpKq020185; Tue, 22 Jan 2008 11:18:51 GMT (envelope-from keramida@repoman.freebsd.org) Received: (from keramida@localhost) by repoman.freebsd.org (8.14.1/8.14.1/Submit) id m0MBIpN4020184; Tue, 22 Jan 2008 11:18:51 GMT (envelope-from keramida) Message-Id: <200801221118.m0MBIpN4020184@repoman.freebsd.org> From: Giorgos Keramidas Date: Tue, 22 Jan 2008 11:18:51 +0000 (UTC) To: src-committers@FreeBSD.org, cvs-src@FreeBSD.org, cvs-all@FreeBSD.org X-FreeBSD-CVS-Branch: HEAD Cc: Subject: cvs commit: src/usr.sbin/iostat iostat.c X-BeenThere: cvs-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: CVS commit messages for the entire tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 22 Jan 2008 11:18:52 -0000 keramida 2008-01-22 11:18:51 UTC FreeBSD src repository (doc committer) Modified files: usr.sbin/iostat iostat.c Log: Repeat iostat header after rows-3 instead of a hardcoded 20. Use ioctl() to get the window size in iostat(8), and force a new header to be prepended to the output every time the current window size changes. Change the number of lines before each header to `rows - 3' when the terminal is resized, so that the full terminal length can be used for output lines. PR: bin/119705 Submitted by: keramida Approved by: maxim MFC after: 2 weeks Revision Changes Path 1.40 +71 -3 src/usr.sbin/iostat/iostat.c