Re: how to correctly react on exception in pfree function? - Mailing list pgsql-hackers

From Tom Lane
Subject Re: how to correctly react on exception in pfree function?
Date
Msg-id 890991.1665632072@sss.pgh.pa.us
Whole thread Raw
In response to Re: how to correctly react on exception in pfree function?  (Julien Rouhaud <rjuju123@gmail.com>)
Responses Re: how to correctly react on exception in pfree function?  (Julien Rouhaud <rjuju123@gmail.com>)
List pgsql-hackers
Julien Rouhaud <rjuju123@gmail.com> writes:
> On Wed, Oct 12, 2022 at 11:08:25PM -0400, Tom Lane wrote:
>> It may be worth looking at the GUC code, which has been dealing
>> with the same sorts of issues pretty successfully for many years.

> The GUC code relies on malloc/free,

Not for much longer [1].  And no, I don't believe that that patch
makes any noticeable difference in the code's robustness.

In the end, a bug affecting these considerations is a bug to be fixed
once it's found.  Building potentially-themselves-buggy defenses against
hypothetical bugs is an exercise with rapidly diminishing returns.

            regards, tom lane

[1] https://www.postgresql.org/message-id/flat/2982579.1662416866@sss.pgh.pa.us



pgsql-hackers by date:

Previous
From: Julien Rouhaud
Date:
Subject: Re: how to correctly react on exception in pfree function?
Next
From: Richard Guo
Date:
Subject: Re: Use LIMIT instead of Unique for DISTINCT when all distinct pathkeys are redundant