public inbox for glibc-bugs@sourceware.org help / color / mirror / Atom feed
From: "bugdal at aerifal dot cx" <sourceware-bugzilla@sourceware.org> To: glibc-bugs@sourceware.org Subject: [Bug time/31558] New: mktime wildly mishandles times near Pacific/Apia tz discontinuity Date: Mon, 25 Mar 2024 20:42:45 +0000 [thread overview] Message-ID: <bug-31558-131@http.sourceware.org/bugzilla/> (raw) https://sourceware.org/bugzilla/show_bug.cgi?id=31558 Bug ID: 31558 Summary: mktime wildly mishandles times near Pacific/Apia tz discontinuity Product: glibc Version: unspecified Status: UNCONFIRMED Severity: normal Priority: P2 Component: time Assignee: unassigned at sourceware dot org Reporter: bugdal at aerifal dot cx Target Milestone: --- Given tm_year=2011-1900, tm_mon=12-1, tm_mday=31, all other fields 0, and TZ=Pacific/Apia, glibc mktime produces an output of 2012-01-01 01:00:00 (time_t 1325329200), offset a whole day forward from what it should be. The affected input is not even a time in the omitted day (2011-12-30 does not exist in this zone) but 1 hour into the following day, which exists. The problem seems to be related to how tm_isdst=0 is being applied - DST is active at this time - but with or without it applied, the time never falls into the limbo day. Discovered as part of a monster thread about the topic of this zone transition on the musl libc mailing list. -- You are receiving this mail because: You are on the CC list for the bug.
next reply other threads:[~2024-03-25 20:42 UTC|newest] Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top 2024-03-25 20:42 bugdal at aerifal dot cx [this message] 2024-03-27 16:49 ` [Bug time/31558] " schwab@linux-m68k.org 2024-03-27 17:00 ` bugdal at aerifal dot cx 2024-03-27 18:23 ` schwab@linux-m68k.org 2024-03-28 12:48 ` schwab@linux-m68k.org 2024-03-28 21:01 ` eggert at cs dot ucla.edu 2024-04-02 11:08 ` schwab@linux-m68k.org 2024-04-02 13:07 ` bugdal at aerifal dot cx 2024-04-02 16:42 ` eggert at cs dot ucla.edu 2024-04-02 17:07 ` bugdal at aerifal dot cx 2024-04-02 18:52 ` eggert at cs dot ucla.edu
Reply instructions: You may reply publicly to this message via plain-text email using any one of the following methods: * Save the following mbox file, import it into your mail client, and reply-to-all from there: mbox Avoid top-posting and favor interleaved quoting: https://en.wikipedia.org/wiki/Posting_style#Interleaved_style * Reply using the --to, --cc, and --in-reply-to switches of git-send-email(1): git send-email \ --in-reply-to=bug-31558-131@http.sourceware.org/bugzilla/ \ --to=sourceware-bugzilla@sourceware.org \ --cc=glibc-bugs@sourceware.org \ /path/to/YOUR_REPLY https://kernel.org/pub/software/scm/git/docs/git-send-email.html * If your mail client supports setting the In-Reply-To header via mailto: links, try the mailto: linkBe sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox; as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).