Re: pg_upgrade: fix memory leak in SLRU I/O code

Поиск
Список
Период
Сортировка
От Álvaro Herrera
Тема Re: pg_upgrade: fix memory leak in SLRU I/O code
Дата
Msg-id 202602051024.2j4dpyfy22zr@alvherre.pgsql
обсуждение исходный текст
Ответ на Re: pg_upgrade: fix memory leak in SLRU I/O code  (Chao Li <li.evan.chao@gmail.com>)
Список pgsql-hackers
On 2026-Feb-05, Chao Li wrote:

> Exactly. In this case, memory leaking is not a problem at all. My
> thinking was that once we do decide to free the top-level object, it
> feels more consistent and less surprising to also free what it owns,
> even if the lifetime is effectively the whole process. It’s less about
> resource pressure and more about keeping the ownership model clear for
> future readers and maintenance.

Maybe we should just change the "pg_free(state)" to "/* no point freeing
memory */" or something like that.

-- 
Álvaro Herrera         PostgreSQL Developer  —  https://www.EnterpriseDB.com/
"We're here to devour each other alive"            (Hobbes)



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