Re: Use-after-free in reorderbuffer.c for INSERT ON CONFLICT - Mailing list pgsql-bugs

From Masahiko Sawada
Subject Re: Use-after-free in reorderbuffer.c for INSERT ON CONFLICT
Date
Msg-id CAD21AoD7J9YNZ0uoxWJyxxQtYbZXNKD6k_52-Ww2P3vw-67c7Q@mail.gmail.com
Whole thread Raw
In response to Use-after-free in reorderbuffer.c for INSERT ON CONFLICT  (Michael Paquier <michael@paquier.xyz>)
Responses Re: Use-after-free in reorderbuffer.c for INSERT ON CONFLICT
List pgsql-bugs
On Wed, Jul 30, 2025 at 11:44 PM Michael Paquier <michael@paquier.xyz> wrote:
>
> A simple solution suggested by Ethan would be to use the "prev_lsn"
> guessed from the change at the beginning of the loop, rather than the
> problematic change->lsn.  But that does not seem completely right to
> me because we can switch to "specinsert" as the change to process,
> hence wouldn't we want to call update_progress_txn() based on the LSN
> of the actual change we are looking at?  All that leads me to the
> attached.

Thank you for preparing the patch!

Yes, I think it's sensible to keep the current behavior. So the patch
looks good to me.

Regards,

--
Masahiko Sawada
Amazon Web Services: https://aws.amazon.com



pgsql-bugs by date:

Previous
From: Peter Eisentraut
Date:
Subject: Re: BUG #19000: gist index returns inconsistent result with gist_inet_ops
Next
From: Tom Lane
Date:
Subject: Re: BUG #19000: gist index returns inconsistent result with gist_inet_ops