Re: [PATCH] Fix memory leak in pg_config

From: Ivan Kush <ivan(dot)kush(at)tantorlabs(dot)com>
To: Michael Paquier <michael(at)paquier(dot)xyz>, Andres Freund <andres(at)anarazel(dot)de>
Cc: Andrey Borodin <x4mmm(at)yandex-team(dot)ru>, pgsql-hackers mailing list <pgsql-hackers(at)lists(dot)postgresql(dot)org>
Subject: Re: [PATCH] Fix memory leak in pg_config
Date: 2026-07-22 11:54:17
Message-ID: 5718ea33-b246-45bd-bc79-8a77731d6c5a@tantorlabs.com
Views: Whole Thread | Raw Message | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

If the project policy is to ignore leaks in short-lived binaries, why
are those known cases not listed explicitly in an LSan suppression file
(for example, see attached patch)?

Disabling leak detection globally with detect_leaks=0 also hides leaks
that may be relevant in long-running processes. Explicit suppressions
would document the intentionally ignored cases while preserving LSan
coverage for the rest of the code.

Regards,
Ivan

On 26-07-22 01:38, Michael Paquier wrote:
>
> None of the changes proposed in the patch are worth caring about. The
> only memory leaks I would care about in the frontend binaries are
> those where we could run a tool in an infinite loop where the
> non-freed would bloat. One example of that is pg_receivewal without
> --no-loop, that could be used as a service to get WAL from a remote
> source.
> --
> Michael

--
Best wishes,
Ivan Kush
Tantor Labs LLC

Attachment Content-Type Size
v3-0001-Add-LeakSanitizer-suppression-for-pg_config.patch text/x-patch 1.9 KB

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message xiaoyu liu 2026-07-22 11:55:50 Re: Many of psql's describe functions bloat cache / waste mem
Previous Message Ayush Tiwari 2026-07-22 11:44:53 Re: Proposal: INSERT ... BY NAME