pg.ddx.io  pgsql-committers@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Peter Eisentraut <peter@eisentraut.org>
To: pgsql-committers@lists.postgresql.org
Subject: pgsql: libpq: Use strerror_r instead of strerror
Date: Sun, 28 Jul 2024 08:29:28 +0000
Message-ID: <E1sXzHU-001Zld-B7@gemulon.postgresql.org> (raw)

libpq: Use strerror_r instead of strerror

Commit 453c4687377 introduced a use of strerror() into libpq, but that
is not thread-safe.  Fix by using strerror_r() instead.

In passing, update some of the code comments added by 453c4687377, as
we have learned more about the reason for the change in OpenSSL that
started this.

Reviewed-by: Daniel Gustafsson <daniel@yesql.se>
Discussion: Discussion: https://postgr.es/m/b6fb018b-f05c-4afd-abd3-318c649faf18@highgo.ca

Branch
------
REL_13_STABLE

Details
-------
https://git.postgresql.org/pg/commitdiff/da5d7a7712549067c04aac013d95d929a8318785

Modified Files
--------------
src/backend/libpq/be-secure-openssl.c    |  9 +++++----
src/interfaces/libpq/fe-secure-openssl.c | 11 ++++++-----
2 files changed, 11 insertions(+), 9 deletions(-)



view thread (7+ messages)  latest in thread

Message-ID: <E1sXzHU-001Zld-B7@gemulon.postgresql.org>
Permalink:  ../E1sXzHU-001Zld-B7@gemulon.postgresql.org/
Also on:    postgresql.org/message-id/E1sXzHU-001Zld-B7@gemulon.postgresql.org

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients using the --to and --cc options:
  reply via email

  To: pgsql-committers@postgresql.org
  Cc: peter@eisentraut.org, pgsql-committers@lists.postgresql.org
  Subject: Re: pgsql: libpq: Use strerror_r instead of strerror
  In-Reply-To: <E1sXzHU-001Zld-B7@gemulon.postgresql.org>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox