Re: BUG #17158: Distinct ROW fails with Postgres 14 - Mailing list pgsql-bugs

From Peter Eisentraut
Subject Re: BUG #17158: Distinct ROW fails with Postgres 14
Date
Msg-id c96d3fa6-174c-2330-bee9-fce4894a8333@enterprisedb.com
Whole thread Raw
In response to Re: BUG #17158: Distinct ROW fails with Postgres 14  (Tom Lane <tgl@sss.pgh.pa.us>)
List pgsql-bugs
On 14.09.21 17:02, Tom Lane wrote:
> Peter Eisentraut <peter.eisentraut@enterprisedb.com> writes:
>> On 10.09.21 21:27, Tom Lane wrote:
>>> Perhaps it'd work to put the phony entry into fcinfo->flinfo->fn_mcxt
>>> instead of CacheMemoryContext.
> 
>> Ok, the attached patch fixes the valgrind error.
> 
> Looks roughly sane to me.  I'm of two minds about whether you
> ought to change the palloc to palloc0.  We'd have taken much
> longer to notice this problem if palloc0 had been used; but
> from any standpoint other than "will valgrind catch it", it
> seems like zeroing the fake typcache entry would be safer.

Yeah, pushed with the palloc0.



pgsql-bugs by date:

Previous
From: Peter Smith
Date:
Subject: Re: bugs or my fault
Next
From: Yudianto Prasetyo
Date:
Subject: Re: bugs or my fault