Re: [EXTERNAL] Re: Crash in record_type_typmod_compare - Mailing list pgsql-hackers

From Jeff Davis
Subject Re: [EXTERNAL] Re: Crash in record_type_typmod_compare
Date
Msg-id 1913a3e8399214325b8ee61c09608a64a7d81eb5.camel@j-davis.com
Whole thread Raw
In response to Re: [EXTERNAL] Re: Crash in record_type_typmod_compare  (Sait Talha Nisanci <Sait.Nisanci@microsoft.com>)
List pgsql-hackers
On Mon, 2021-04-05 at 12:07 +0000, Sait Talha Nisanci wrote:
> Hi Andres,
> 
> Please see the updated patch, do you mean something like this? (there
> might be a simpler way for doing this)
> 

Committed with minor revisions.

My patch also avoids incrementing NextRecordTypmod until we've already
called CreateTupleDescCopy(). Otherwise, an allocation failure could
leave NextRecordTypmod unnecessarily incremented, which is a tiny leak.

Regards,
    Jeff Davis





pgsql-hackers by date:

Previous
From: Tom Lane
Date:
Subject: Re: pgsql: Fix numeric_mul() overflow due to too many digits after decimal
Next
From: Dean Rasheed
Date:
Subject: Re: pgsql: Fix numeric_mul() overflow due to too many digits after decimal