bin/119705: [PATCH] make iostat a bit smarter about the number
of tty rows
Giorgos Keramidas
keramida at FreeBSD.org
Wed Jan 16 07:20:03 UTC 2008
The following reply was made to PR bin/119705; it has been noted by GNATS.
From: Giorgos Keramidas <keramida at freebsd.org>
To: Maxim Konovalov <maxim at macomnet.ru>
Cc: Bruce Evans <bde at freebsd.org>, bug-followup at freebsd.org
Subject: Re: bin/119705: [PATCH] make iostat a bit smarter about the number
of tty rows
Date: Wed, 16 Jan 2008 09:13:28 +0200
On 2008-01-16 09:29, Maxim Konovalov <maxim at macomnet.ru> wrote:
> Hi Giorgos,
> It seems for me you forget to clear wresized flag -- I added
> printf("%s\n", __func__); at the beginning of doresize() to notice
> this.
Indeed. Thanks for catching this.
> IMHO the isatty() check doesn't belong to a pseudo signal handler
> doresize(). Install SIGWINCH handler if and only if stdout is a tty.
That's a good suggestion too, and it will save one isatty() call for
each SIGWINCH delivery. I'll update the patch and follow-up with a
second version in the PR. Nice...
> Do you have plans to add this feature to netstat, vmstat and all other
> similar tools? :-)
That didn't occur to me, but it's probably a good idea :)
More information about the freebsd-bugs
mailing list