diff options
Diffstat (limited to 'src/backend/access/index/genam.c')
-rw-r--r-- | src/backend/access/index/genam.c | 8 |
1 files changed, 2 insertions, 6 deletions
diff --git a/src/backend/access/index/genam.c b/src/backend/access/index/genam.c index 886c05655f4..8f532e14590 100644 --- a/src/backend/access/index/genam.c +++ b/src/backend/access/index/genam.c @@ -577,17 +577,13 @@ systable_recheck_tuple(SysScanDesc sysscan, HeapTuple tup) Assert(tup == ExecFetchSlotHeapTuple(sysscan->slot, false, NULL)); - /* - * Trust that table_tuple_satisfies_snapshot() and its subsidiaries - * (commonly LockBuffer() and HeapTupleSatisfiesMVCC()) do not themselves - * acquire snapshots, so we need not register the snapshot. Those - * facilities are too low-level to have any business scanning tables. - */ freshsnap = GetCatalogSnapshot(RelationGetRelid(sysscan->heap_rel)); + freshsnap = RegisterSnapshot(freshsnap); result = table_tuple_satisfies_snapshot(sysscan->heap_rel, sysscan->slot, freshsnap); + UnregisterSnapshot(freshsnap); /* * Handle the concurrent abort while fetching the catalog tuple during |