Re: BUG #17607: Server process crashes when PLpgSQL function raises error in subtransaction
Tom Lane <tgl@sss.pgh.pa.us>
From: Tom Lane <tgl@sss.pgh.pa.us>
To: Alvaro Herrera <alvherre@alvh.no-ip.org>
Cc: thomas.d.mckay@gmail.com, pgsql-bugs@lists.postgresql.org
Date: 2022-09-25T20:34:05Z
Lists: pgsql-bugs
Attachments
- fix-trigger-tupdesc-refcount-issue-3.patch (text/x-diff) patch
... and after yet more poking at it, I see why c5b7ba4e6 masked the problem: it added an optimization such that we don't use the storeslot at all unless a tuple mapping conversion is required. That led me to the test case shown in the attached, which exhibits this symptom in all branches since v12. I had been planning to let this wait until after 15rc1 wrap, but now that I have evidence that the bug is still live in v15, I'm going to go ahead and push. Both components of the fix seem like extremely safe changes, even for the day before wrap. regards, tom lane
Commits
-
Fix tupdesc lifespan bug with AfterTriggersTableData.storeslot.
- c82766c0298a 15.0 landed
- 9923764614a0 14.6 landed
- 8c17c8615470 13.9 landed
- 51976309450c 12.13 landed
- 216f9c1ab3a4 16.0 landed