postgres.git / summary / log / commit / refs
commit d765226cb9d2e1f4a1efcf45f8e729aafc0e0ddf
Author: Heikki Linnakangas <heikki.linnakangas@iki.fi>
Date: Mon Mar 10 16:54:58 2025 +0000
First released in: 18.0, 13.21, 14.18, 15.13, 16.9, 17.5
Fix a few more redundant calls of GetLatestSnapshot()
Commit 2367503177 fixed this in RelationFindReplTupleByIndex(), but I
missed two other similar cases.
Per report from Ranier Vilela.
Discussion: https://www.postgresql.org/message-id/CAEudQArUT1dE45WN87F-Gb7XMy_hW6x1DFd3sqdhhxP-RMDa0Q@mail.gmail.com
Backpatch-through: 13
src/backend/executor/execReplication.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/src/backend/executor/execReplication.c b/src/backend/executor/execReplication.c
index 6538e6b9c13..c4e33d58f4e 100644
--- a/src/backend/executor/execReplication.c
+++ b/src/backend/executor/execReplication.c
@@ -359,7 +359,7 @@ retry:
PushActiveSnapshot(GetLatestSnapshot());
- res = table_tuple_lock(rel, &(outslot->tts_tid), GetLatestSnapshot(),
+ res = table_tuple_lock(rel, &(outslot->tts_tid), GetActiveSnapshot(),
outslot,
GetCurrentCommandId(false),
lockmode,
[parent: 50c5899922c3]