Hi Rahila,
On Wed, Dec 17, 2025 at 3:57 PM Rahila Syed <rahilasyed90@gmail.com> wrote:
>
> Hi Amit,
>
>
>>
>> Oops, forgot an #include. Fixed in the attached.
>>
>
> Thank you for the updated patch and the detailed commit message. You have explained the problem
> quite well and the changes look good to me.
Thanks for looking.
> I would just add one more comment, which I have attached as a separate patch with this email.
> Please have a look.
/*
* Release any LWLocks we might be holding, before running callbacks that
- * may detach the memory containing those locks.
+ * may detach the memory containing those locks. Releasing all the locks
+ * ensures that any callbacks executed afterward will be able to acquire
+ * any lock.
*/
Hmm, I'm not sure I follow. Maybe it has to do with something you
were trying to do when you ran into this bug, but why would callbacks
be acquiring locks after an error and why would it be safe to do so?
Are you saying that LWLockReleaseAll() cleans up unsafe-to-access
locks so that new ones can be taken after that point?
--
Thanks, Amit Langote