aboutsummaryrefslogtreecommitdiff
path: root/src/backend/commands/copyfromparse.c
diff options
context:
space:
mode:
authorHeikki Linnakangas <heikki.linnakangas@iki.fi>2024-10-21 09:49:21 +0300
committerHeikki Linnakangas <heikki.linnakangas@iki.fi>2024-10-21 09:49:21 +0300
commit1a43de5e0a591b66ef3d92f3fac5aefcc2dc02fe (patch)
treebee9af91084f1c4c5202d0bfc5bc4a9097a48996 /src/backend/commands/copyfromparse.c
parent57a36e890d3d60e6408bf6805e91c82f7b370873 (diff)
downloadpostgresql-1a43de5e0a591b66ef3d92f3fac5aefcc2dc02fe.tar.gz
postgresql-1a43de5e0a591b66ef3d92f3fac5aefcc2dc02fe.zip
Fix race condition in committing a serializable transaction
The finished transaction list can contain XIDs that are older than the serializable global xmin. It's a short-lived state; ClearOldPredicateLocks() removes any such transactions from the list, and it's called whenever the global xmin advances. But if another backend calls SummarizeOldestCommittedSxact() in that window, it will call SerialAdd() on an XID that's older than the global xmin, or if there are no more transactions running, when global xmin is invalid. That trips the assertion in SerialAdd(). Fixes bug #18658 reported by Andrew Bille. Thanks to Alexander Lakhin for analysis. Backpatch to all versions. Discussion: https://www.postgresql.org/message-id/18658-7dab125ec688c70b%40postgresql.org
Diffstat (limited to 'src/backend/commands/copyfromparse.c')
0 files changed, 0 insertions, 0 deletions