Re: PostgreSQL 17: Bug in libpq when libpq is dlopened/closed multiple times

From: Jacob Champion <jacob(dot)champion(at)enterprisedb(dot)com>
To: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
Cc: PostgreSQL Hackers <pgsql-hackers(at)lists(dot)postgresql(dot)org>, Daniel Schreiber <daniel(dot)schreiber(at)hrz(dot)tu-chemnitz(dot)de>
Subject: Re: PostgreSQL 17: Bug in libpq when libpq is dlopened/closed multiple times
Date: 2026-04-22 22:10:31
Message-ID: CAOYmi+=ezP7DSyTKh9xy3ejTxydrVicBYBYeoVZOWgYvAyjDxA@mail.gmail.com
Views: Whole Thread | Raw Message | Download mbox | Resend email
Thread:
Lists: pgsql-bugs pgsql-hackers

On Wed, Apr 22, 2026 at 12:23 PM Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> wrote:
> I agree that we have no real ability to guarantee that.
> Still, as far as the presented patch goes, it seems like a clear
> win so I'd vote for fix-and-backpatch.

Sounds good to me.

> Should we write the arguments as BIO_TYPE_NONE | BIO_TYPE_SOURCE_SINK
> rather than just BIO_TYPE_SOURCE_SINK?

Good question... Popularity-wise, the shorter spelling shows up across
quite a few projects on GitHub, but the only spelling of
`BIO_meth_new(BIO_TYPE_NONE | ...)` that I can find is a single place
inside OpenSSL's own test suite -- which also uses the shorter
alternative, in two places. So my vote is BIO_TYPE_SOURCE_SINK; we'll
be in good company.

Thanks,
--Jacob

In response to

Responses

Browse pgsql-bugs by date

  From Date Subject
Next Message Tom Lane 2026-04-22 22:13:28 Re: PostgreSQL 17: Bug in libpq when libpq is dlopened/closed multiple times
Previous Message Jacob Champion 2026-04-22 22:10:07 Re: PostgreSQL 17: Bug in libpq when libpq is dlopened/closed multiple times

Browse pgsql-hackers by date

  From Date Subject
Next Message Tom Lane 2026-04-22 22:13:28 Re: PostgreSQL 17: Bug in libpq when libpq is dlopened/closed multiple times
Previous Message Jacob Champion 2026-04-22 22:10:07 Re: PostgreSQL 17: Bug in libpq when libpq is dlopened/closed multiple times