public inbox for glibc-bugs@sourceware.org
help / color / mirror / Atom feed
From: "fweimer at redhat dot com" <sourceware-bugzilla@sourceware.org>
To: glibc-bugs@sourceware.org
Subject: [Bug time/30701] getutxent misbehaves on 32-bit x86 when _TIME_BITS=64
Date: Fri, 03 May 2024 07:29:51 +0000	[thread overview]
Message-ID: <bug-30701-131-GEcBzBq8dS@http.sourceware.org/bugzilla/> (raw)
In-Reply-To: <bug-30701-131@http.sourceware.org/bugzilla/>

https://sourceware.org/bugzilla/show_bug.cgi?id=30701

--- Comment #7 from Florian Weimer <fweimer at redhat dot com> ---
(In reply to Bruno Haible from comment #4)
> While doing this conversion, the code could interpret the 'tv_sec' field as
> an 'unsigned int' (as opposed to an 'int'). This would solve the year 2038
> problem at this place. Suggested by Andreas Schwab in
> https://sourceware.org/pipermail/libc-alpha/2023-August/150661.html .

This has been implemented in glibc 2.40 via:

commit 5361ad3910c257bc327567be76fde532ed238e42
Author: Florian Weimer <fweimer@redhat.com>
Date:   Fri Apr 19 14:38:17 2024 +0200

    login: Use unsigned 32-bit types for seconds-since-epoch

    These fields store timestamps when the system was running.  No Linux
    systems existed before 1970, so these values are unused.  Switching
    to unsigned types allows continued use of the existing struct layouts
    beyond the year 2038.

    The intent is to give distributions more time to switch to improved
    interfaces that also avoid locking/data corruption issues.

    Reviewed-by: Adhemerval Zanella  <adhemerval.zanella@linaro.org>

No backports planned.

-- 
You are receiving this mail because:
You are on the CC list for the bug.

  parent reply	other threads:[~2024-05-03  7:29 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-07-30 20:07 [Bug time/30701] New: " eggert at cs dot ucla.edu
2023-07-31  6:42 ` [Bug time/30701] " bruno at clisp dot org
2023-07-31  9:49 ` sam at gentoo dot org
2023-08-01  9:10 ` aurelien at aurel32 dot net
2023-08-01 14:19 ` jwilk at jwilk dot net
2023-08-05 18:27 ` eggert at cs dot ucla.edu
2023-08-14 13:12 ` bruno at clisp dot org
2023-08-14 13:20 ` bruno at clisp dot org
2024-04-09  7:17 ` fweimer at redhat dot com
2024-04-15 11:52 ` fweimer at redhat dot com
2024-05-03  7:29 ` fweimer at redhat dot com
2024-05-03  7:29 ` fweimer at redhat dot com [this message]
2024-05-06 22:54 ` lksfbdij at 10mail dot org
2024-05-06 23:36 ` fweimer at redhat dot com

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-30701-131-GEcBzBq8dS@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: link
Be 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).