Re: Valgrind - showing memory leaks

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Álvaro Herrera <alvherre(at)kurilemu(dot)de>
Cc: Yasir <yasir(dot)hussain(dot)shah(at)gmail(dot)com>, PostgreSQL Hackers <pgsql-hackers(at)lists(dot)postgresql(dot)org>
Subject: Re: Valgrind - showing memory leaks
Date: 2025-05-11 15:13:18
Message-ID: 891693.1746976398@sss.pgh.pa.us
Views: Whole Thread | Raw Message | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

=?utf-8?Q?=C3=81lvaro?= Herrera <alvherre(at)kurilemu(dot)de> writes:
> On 2025-May-08, Tom Lane wrote:
>> So it seems like valgrind is wrong here, or else we're leaking the
>> whole rd_att structure later on somehow.

> Well, the problem is that if num_check is zero, FreeTupleDesc() doesn't
> free ->check.

Ah-hah.

> Done that way, thanks.

Thanks! I've been putting together a list of fixes to make
Valgrind less noisy, and it just got one shorter.

regards, tom lane

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Xuneng Zhou 2025-05-11 15:19:22 Re: Add an option to skip loading missing publication to avoid logical replication failure
Previous Message Dagfinn Ilmari Mannsåker 2025-05-11 14:54:50 Re: add tab-complete for ALTER DOMAIN ADD...