Re: warn if GUC set to an invalid shared library

Поиск
Список
Период
Сортировка
От Justin Pryzby
Тема Re: warn if GUC set to an invalid shared library
Дата
Msg-id Zp6IpxVT1U-qmMOC@pryzbyj2023
обсуждение исходный текст
Ответ на Re: warn if GUC set to an invalid shared library  (Robert Haas <robertmhaas@gmail.com>)
Список pgsql-hackers
On Fri, May 24, 2024 at 01:15:13PM -0400, Robert Haas wrote:
> + /* Note that filename was already canonicalized */
> 
> I see that this comment is copied from load_libraries(), but I don't
> immediately see where the canonicalization actually happens. Do you
> know, or can you find out? Because that's crucial here, else stat()
> might not target the real filename. I wonder if it will anyway. Like,
> couldn't the library be versioned, and might not dlopen() try a few
> possibilities?

This comment made me realize that we've been fixated on the warning.
But the patch was broken, and would've always warned.  I think almost
all of the previous patch versions had this issue - oops.

I added a call to expand_dynamic_library_name(), which seems to answer
your question.

And added a preparatory patch to distinguish ALTER USER/DATABASE SET
from SET in a function, to avoid warning in that case.

-- 
Justin

Вложения

В списке pgsql-hackers по дате отправления:

Предыдущее
От: Masahiko Sawada
Дата:
Сообщение: Re: xid_wraparound tests intermittent failure.
Следующее
От: Jeff Davis
Дата:
Сообщение: Re: [18] Policy on IMMUTABLE functions and Unicode updates