tech-userlevel archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
Re: strftime(3) oddities with %s, %z
On Sun, Nov 06, 2022 at 05:31:59PM +0000, David Holland wrote:
> > [Aside: a truly bizarre factoid - when we do eventually claim, in
> > unistd.h, that we support Posix.7 (ie: 2008) rather than Posix.6 (2001)
> > the support we have for strftime_l() will actually vanish - the function
> > will still be there, but will simply be a clone of strftime(),
> > ignoring the passed in locale. That wacky logic comes from
> > tzcode, as many users of it have no locale handling at all,
> > so our implementation will need local fixing sometime].
>
> Can you file a PR on that? It seems likely that if nobody does
> anything about it sooner or later the way we'll discover it again is
> by random barely-debuggable browser or JVM misbehavior.
The plot thickens! This is not true. There are two copies of
strftime_l in strftime.c, one that works and one that behaves as you
describe; the latter one is inside #if HAVE_STRFTIME_L, which I guess
is false. So I guess if the _POSIX_VERSION gets bumped it'll just
break the build. :-)
Any reason not to remove that one?
--
David A. Holland
dholland%netbsd.org@localhost
- References:
- Re: strftime(3) oddities with %s, %z
- Re: strftime(3) oddities with %s, %z
- strftime(3) oddities with %s, %z
- Re: strftime(3) oddities with %s, %z
- Re: strftime(3) oddities with %s, %z
- Re: strftime(3) oddities with %s, %z
- Re: strftime(3) oddities with %s, %z
- Re: strftime(3) oddities with %s, %z
- Re: strftime(3) oddities with %s, %z
- Re: strftime(3) oddities with %s, %z
Home |
Main Index |
Thread Index |
Old Index