Avoid resource leak (src/bin/pg_resetwal/pg_resetwal.c)

Поиск
Список
Период
Сортировка
Искать

Avoid resource leak (src/bin/pg_resetwal/pg_resetwal.c)

От:
Ranier Vilela <ranier.vf@gmail.com>
Дата:
Вложения:
Hi.

Per Coverity.

The function *read_controlfile* is responsible for updating old pg_control versions.
Coverity complains that the struct ControlFileData buffer is leaked.

I think that is right.

Trivial patch attached.

best regards,
Ranier Vilela

Re: Avoid resource leak (src/bin/pg_resetwal/pg_resetwal.c)

От:
Michael Paquier <michael@paquier.xyz>
Дата:
Вложения:
On Thu, Oct 23, 2025 at 09:26:24PM -0300, Ranier Vilela wrote:
> The function *read_controlfile* is responsible for updating old pg_control
> versions.
> Coverity complains that the struct ControlFileData buffer is leaked.
> 
> I think that is right.

Bis repetita.  Allocation in the context of a short-term binary
execution.
--
Michael
FAQ