Re: BUG #17462: Invalid memory access in heapam_tuple_lock
Andres Freund <andres@anarazel.de>
From: Andres Freund <andres@anarazel.de>
To: Tom Lane <tgl@sss.pgh.pa.us>
Cc: anisimow.d@gmail.com, pgsql-bugs@lists.postgresql.org
Date: 2022-04-11T20:32:03Z
Lists: pgsql-bugs
Hi, On 2022-04-11 15:59:30 -0400, Tom Lane wrote: > Andres Freund <andres@anarazel.de> writes: > > On 2022-04-11 15:25:12 -0400, Tom Lane wrote: > >> That seems like a fairly clean idea, although I think we can't use it > >> in the back branches without an ABI break. We're not going to find a > >> TID's worth of padding space in struct SnapshotData. > > > I guess we could put members of SnapshotData into a union with ItemPointerData > > that aren't used by InitDirtySnapshot()/HeapTupleSatisfiesDirty(). > > Yeah, that could work. You want to draft a patch, or shall I? If you would, I'd appreciate it. I've to finish a talk I'm giving tomorrow, and I want to fix the recovery conflict bug - it's triggering the bug like half the time on CI... Greetings, Andres Freund
Commits
-
Prevent access to no-longer-pinned buffer in heapam_tuple_lock().
- 7b7ed046cb2a 15.0 landed
- e0ed20d0b66e 12.11 landed
- c590e514a90d 14.3 landed
- 44096c31eaf0 13.7 landed
-
Add Valgrind buffer access instrumentation.
- 1e0dfd166b3f 14.0 cited
-
tableam: Add tuple_{insert, delete, update, lock} and use.
- 5db6df0c0117 12.0 cited