NetBSD-Bugs archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Re: lib/36528 (strptime(3) doesn't fill in the 'tm' structure fields correctly)

The following reply was made to PR lib/36528; it has been noted by GNATS.

From: Robert Elz <kre%munnari.OZ.AU@localhost>
To: David Holland <>
Subject: Re: lib/36528 (strptime(3) doesn't fill in the 'tm' structure fields correctly)
Date: Mon, 15 May 2023 11:40:28 +0700

     Date:        Sun, 14 May 2023 22:11:41 +0000
     From:        David Holland <>
     Message-ID:  <>
   | This is _all_ it says; it doesn't define what is appropriate,
 Absolutely, you clearly didn't really pay attention to my original
 message on this subject.   The implementation is allowed to do almost
 anything.   That's why this was never a bug, not in our (then)
 implementation, not in the current one, and not in the linux one (as
 reported in the PR) either, but an application error.
 Of course, if the implementation doesn't fill in at least the fields
 that match the format specification, that would be useless (and POSIX
 probably needs to be fixed to be mor explicit about which ones need
 to be modified, rather than just saying "appropriate").
   | Furthermore, even if it is not _required_ it is clearly _permitted_
 True, no-one ever said otherwise.
   | and also desirable.
 That's debatable - it is kind of pointless, as the application isn't
 allowed (if it wants to be portable) to depend upon any of that.   That's
 why the original report was incorrect - the original implementation (not
 that I have gone back to look at a NetBSD 4 vintage strptime() to check
 what it was doing) was probably fine.   What was broken was the assumption
 as to what was supposed to happen (the PR even said that all the BSDs and
 MacOS did it the "wrong" way, and only linux and solaris the "right" way).
   | In any event it's a moot point.
 Yes.    Not sure why you bothered to comment on my initial message.

Home | Main Index | Thread Index | Old Index