Date: Tue, 9 Dec 2003 20:58:02 +1100 (EST) From: Bruce Evans <bde@zeta.org.au> To: Dag-Erling =?iso-8859-1?q?Sm=F8rgrav?= <des@des.no> Cc: src-committers@FreeBSD.org Subject: Re: cvs commit: src/usr.bin/vmstat vmstat.c Message-ID: <20031209205728.A4462@gamplex.bde.org> In-Reply-To: <20031209011521.J6926@gamplex.bde.org> References: <200312080757.hB87vvTA048651@repoman.freebsd.org> <20031208225505.H6229@gamplex.bde.org> <xzpy8tn5wqs.fsf@dwp.des.no> <20031208235157.U6502@gamplex.bde.org> <20031209011521.J6926@gamplex.bde.org>
next in thread | previous in thread | raw e-mail | index | archive | help
[Resending after bounce]
On Mon, 8 Dec 2003, Dag-Erling [iso-8859-1] Smørgrav wrote:
> Bruce Evans <bde@zeta.org.au> writes:
> > for (i = 0; i < nintr; i++) {
> > clen = strlen(tintrname);
> > +
> > + /* Work around bogus padding in new interrupt code. */
> > + while (clen > 0 && tintrname[clen - 1] == ' ')
> > + clen--;
> > +
> > if (clen > istrnamlen)
> > istrnamlen = clen;
> > tintrname += clen + 1;
> > }
>
> This is wrong. You can't possibly have tested it.
Oops. I tested it on several i386 kernels and it seemed to work. It
may have worked accidentally because the longest string was near the
beginning. I even avoided that bug in a related fix written previously
for systat. Anyway, this is just a reminder to fix the kernel.
Bruce
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20031209205728.A4462>
