printf behaviour with illegal or malformed format string
Poul-Henning Kamp
phk at phk.freebsd.dk
Tue Dec 13 05:01:02 PST 2005
In message <20051213230723.T3248 at epsplex.bde.org>, Bruce Evans writes:
>Now I think they should be very rarely needed and more rarely used.
>Using them mainly gives unportable code that breaks especially badly
>on systems which don't support extensions.
Portability is good, but it shouldn't get in the way of improving
our programs.
>I think these belong in specialized applications or libraries. %T is
>already handled better by strftime/gmtime/localtime.
There's no handling for fractional seconds there.
>I mean aborting instead of returning NULL for failing malloc()s breaks
>defined behaviour.
Right, that's deliberate.
--
Poul-Henning Kamp | UNIX since Zilog Zeus 3.20
phk at FreeBSD.ORG | TCP/IP since RFC 956
FreeBSD committer | BSD since 4.3-tahoe
Never attribute to malice what can adequately be explained by incompetence.
More information about the freebsd-arch
mailing list