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 libc/1890] strerror() unnecessarily non thread-safe
Date: Tue, 12 Dec 2023 11:40:40 +0000 [thread overview]
Message-ID: <bug-1890-131-0kGUpvyiBh@http.sourceware.org/bugzilla/> (raw)
In-Reply-To: <bug-1890-131@http.sourceware.org/bugzilla/>
https://sourceware.org/bugzilla/show_bug.cgi?id=1890
--- Comment #10 from Florian Weimer <fweimer at redhat dot com> ---
(In reply to Bruno Haible from comment #9)
> Note that this return convention (returning a pointer to a per-thread
> buffer) has a pitfall:
> If the returned pointer ever gets passed to a different thread, value
> corruption will occur, that is hard to detect and to debug. (Because while
> the second thread is storing, printing, or logging the value, the first
> thread may write different contents into it.)
This has been clarified in POSIX, and I believe C23. However, it only applies
to the case where an unknown error code is used, so that's why I think a
separate symbol version wasn't necessary.
--
You are receiving this mail because:
You are on the CC list for the bug.
next prev parent reply other threads:[~2023-12-12 11:40 UTC|newest]
Thread overview: 13+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <bug-1890-131@http.sourceware.org/bugzilla/>
2020-12-21 2:43 ` jscott at posteo dot net
2023-06-15 9:48 ` fweimer at redhat dot com
2023-06-15 9:50 ` fweimer at redhat dot com
2023-10-26 23:20 ` gabravier at gmail dot com
2023-11-01 1:59 ` bruno at clisp dot org
2023-12-12 11:40 ` fweimer at redhat dot com [this message]
2023-12-12 12:21 ` bruno at clisp dot org
2023-12-13 9:39 ` fweimer at redhat dot com
2005-11-19 15:15 [Bug libc/1890] New: " stefan dot puiu at gmail dot com
2005-11-22 18:13 ` [Bug libc/1890] " drepper at redhat dot com
2005-11-23 7:35 ` stefan dot puiu at gmail dot com
2005-11-23 8:31 ` drepper at redhat dot com
2005-11-23 9:15 ` stefan dot puiu at gmail dot com
2005-11-23 9:26 ` stefan dot puiu at gmail 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-1890-131-0kGUpvyiBh@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).