Re: [PATCH] Add PQgetThreadLock() to expose the Kerberos/Curl mutex - Mailing list pgsql-hackers

From Nico Williams
Subject Re: [PATCH] Add PQgetThreadLock() to expose the Kerberos/Curl mutex
Date
Msg-id aaJx1XQDWeXKHCaa@ubby
Whole thread Raw
In response to [PATCH] Add PQgetThreadLock() to expose the Kerberos/Curl mutex  (Jacob Champion <jacob.champion@enterprisedb.com>)
Responses Re: [PATCH] Add PQgetThreadLock() to expose the Kerberos/Curl mutex
List pgsql-hackers
On Fri, Feb 27, 2026 at 12:38:34PM -0800, Jacob Champion wrote:
> libpq has some third-party dependencies (currently, Kerberos and Curl)
> that aren't threadsafe in some situations. We protect the affected
> code with a locking callback, and we allow applications to override
> that callback globally because they might also be using those
> third-party dependencies. The history of the API is at [1, 2].

Well, that's ancient stuff.  krb4?  4?!

Anyways, I'm quite curious about any thread safety problems you are
aware of in Kerberos implementations today.  As for curl, it wants to be
initialized much like OpenSSL used to want to be initialized (thankfully
no more), and that's a problem.

Nico
-- 



pgsql-hackers by date:

Previous
From: Tatsuya Kawata
Date:
Subject: Re: [Patch]Add tab completion for DELETE ... USING
Next
From: Amit Kapila
Date:
Subject: Re: Fix slotsync worker busy loop causing repeated log messages