Fix pg_visibility regression failure with CLOBBER_CACHE_ALWAYS
Commit reverted a bit too much code, reintroducing one of the
issues fixed by - a page might have been left partially empty
after relcache invalidation.
Reported-By: Tom Lane
Author: Masahiko Sawada
Discussion:
Discussion:
@@ -407,6 +407,7 @@ RelationGetBufferForTuple(Relation relation, Size len,
* target.
*/
targetBlock = GetPageWithFreeSpace(relation, targetFreeSpace);
+ }
/*
* If the FSM knows nothing of the rel, try the last page before we
@@ -420,7 +421,6 @@ RelationGetBufferForTuple(Relation relation, Size len,
if (nblocks > 0)
targetBlock = nblocks - 1;
}
- }
loop:
while (targetBlock != InvalidBlockNumber)
