[patch] synch src/lib/stdio/vfprintf.c with FreeBSD rev 1.34

Chris Pressey cpressey at catseye.mine.nu
Sat Jan 15 20:59:24 PST 2005


On Thu, 13 Jan 2005 22:36:40 -0800
Chris Pressey <cpressey at xxxxxxxxxxxxxxx> wrote:

> Hi,
> 
> The attached patch synchs DFly's vfprintf.c with FreeBSD's 1.34. 
> Basically this provides support for some C99 format length specifiers
> (z, t, j, hh) and locale-sensitive "thousands" (grouping) seperators.
> 
> It's not been tested yet (buildworld+buildkernel currently in
> progress.)
> 
> Patching was done by hand, due to our style difference from FreeBSD,
> plus I wanted to follow the logic of each of the changes.  They seem
> sound, except for the assumption that quad_t == long long, so (on
> Joerg's advice) I added a compile-time assertion on that assumption.
> 
> Your feedback/review/testing is of course appreciated :)
> 
> Thanks,
> -Chris

Two buildworld+buildkernel cycles later, and everything still seems just
peachy.  Seems to work, too, although the base GCC still complains that
'z' and friends are unknown type conversion characters - that's just
because GCC 2.x doesn't speak C99.

If there are no objections in the next few days I'll commit it.

-Chris





More information about the Submit mailing list