Subject: Re: va_list on PPC (was Re: CVS commit: syssrc/sys/arch/powerpc/include)
To: Matt Thomas <>
From: Thomas Klausner <>
List: tech-toolchain
Date: 08/08/2002 23:15:11
On Wed, Aug 07, 2002 at 05:30:14PM -0700, Matt Thomas wrote:
> The above clearly dictates that:
>         va_start(ap, fmt);
>         vfprintf(fmt, ap);
>         vfprintf(fmt, ap);
>         va_end(ap);
> is not legal and absolutely non-portable.  However, inserting another
> va_end and va_start between the two vfprintf's results in portable
> code.

Last autumn I did an audit on NetBSD for that and fixed all
occurrences of that in the base system (and similar problems like
missing va_end()s).


Thomas Klausner -
Main Rule of Usenet:  Never argue with idiots.  They drag you down to
their level, then beat you with experience.