Subject: Re: Plug minor memleak in pg_dump

From: Michael Paquier <[email-masked]>
Date: Wed, 9 Feb 2022 11:56:46 +0900

On Wed, Feb 02, 2022 at 10:06:13AM +0100, Daniel Gustafsson wrote:
> The leak itself is clearly not something to worry about wrt memory pressure.
> We do read into tmp and free it in other places in the same function though (as
> you note above), so for code consistency alone this is worth doing IMO (and it
> reduces the risk of static analyzers flagging this).
> 
> Unless objected to I will go ahead with getting this committed.

Looks like you forgot to apply that?
--
Michael

---

From: Bharath Rupireddy <[email-masked]>
Date: Wed, 9 Feb 2022 10:32:59 +0530

> Looks like you forgot to apply that?

Attaching the patch that I suggested above, also the original patch
proposed by Georgios is at [1], leaving the decision to the committer
to pick up the best one.

[1] https://www.postgresql.org/message-id/oZwKiUxFsVaetG2xOJp7Hwao8F1AKIdfFDQLNJrnwoaxmjyB-45r_aYmhgXHKLcMI3GT24m9L6HafSi2ns7WFxXe0mw2_tIJpD-Z3vb_eyI%3D%40pm.me

Regards,
Bharath Rupireddy.

---

From: Daniel Gustafsson <[email-masked]>
Date: Wed, 9 Feb 2022 14:14:50 +0100

> On 9 Feb 2022, at 03:56, Michael Paquier <[email-masked]> wrote:
> 

No, but I was distracted by other things leaving this on the TODO list.  It's
been pushed now.

--
Daniel Gustafsson		https://vmware.com/