GNU bug report logs -
#11101
Incorrect relative dates the day after DST switchover
Previous Next
Full log
View this message in rfc822 format
[Message part 1 (text/plain, inline)]
forcemerge 11098 11101
thanks
On 03/27/2012 10:04 AM, chip <at> seraphine.us wrote:
> Shortly after the DST jump in the United States on March 11th, the 'date'
> command returned an incorrect relevant date for the first hour after
> midnight. See text capture below.
Thanks for the report. However, you're the second person this week, and
adding to a long line of duplicate reporters in prior years, to notice
that 'date' is behaving as we have documented it.
https://lists.gnu.org/archive/html/bug-coreutils/2012-03/msg00102.html
'yesterday' means 'subtract 24 hours', but if you start at midnight
after a 23-hour day, subtracting 24 hours really does cross 2 calendar
dates. If you want to avoid this issue, base your relative calculations
off of noon, not midnight, as suggested in our FAQ:
https://www.gnu.org/software/coreutils/faq/#The-date-command-is-not-working-right_002e
> date (GNU coreutils) 5.97
That's rather old; we just released 8.16.
--
Eric Blake eblake <at> redhat.com +1-919-301-3266
Libvirt virtualization library http://libvirt.org
[signature.asc (application/pgp-signature, attachment)]
This bug report was last modified 6 years and 211 days ago.
Previous Next
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.