summaryrefslogtreecommitdiff
path: root/src/backend/access/hash/hashpage.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/backend/access/hash/hashpage.c')
-rw-r--r--src/backend/access/hash/hashpage.c21
1 files changed, 9 insertions, 12 deletions
diff --git a/src/backend/access/hash/hashpage.c b/src/backend/access/hash/hashpage.c
index 2e2588be3b7..178463fcb65 100644
--- a/src/backend/access/hash/hashpage.c
+++ b/src/backend/access/hash/hashpage.c
@@ -161,8 +161,7 @@ _hash_getinitbuf(Relation rel, BlockNumber blkno)
/* ref count and lock type are correct */
/* initialize the page */
- _hash_pageinit(BufferGetPage(buf, NULL, NULL, BGP_NO_SNAPSHOT_TEST),
- BufferGetPageSize(buf));
+ _hash_pageinit(BufferGetPage(buf), BufferGetPageSize(buf));
return buf;
}
@@ -211,8 +210,7 @@ _hash_getnewbuf(Relation rel, BlockNumber blkno, ForkNumber forkNum)
/* ref count and lock type are correct */
/* initialize the page */
- _hash_pageinit(BufferGetPage(buf, NULL, NULL, BGP_NO_SNAPSHOT_TEST),
- BufferGetPageSize(buf));
+ _hash_pageinit(BufferGetPage(buf), BufferGetPageSize(buf));
return buf;
}
@@ -386,7 +384,7 @@ _hash_metapinit(Relation rel, double num_tuples, ForkNumber forkNum)
* the physical index length.
*/
metabuf = _hash_getnewbuf(rel, HASH_METAPAGE, forkNum);
- pg = BufferGetPage(metabuf, NULL, NULL, BGP_NO_SNAPSHOT_TEST);
+ pg = BufferGetPage(metabuf);
pageopaque = (HashPageOpaque) PageGetSpecialPointer(pg);
pageopaque->hasho_prevblkno = InvalidBlockNumber;
@@ -454,7 +452,7 @@ _hash_metapinit(Relation rel, double num_tuples, ForkNumber forkNum)
CHECK_FOR_INTERRUPTS();
buf = _hash_getnewbuf(rel, BUCKET_TO_BLKNO(metap, i), forkNum);
- pg = BufferGetPage(buf, NULL, NULL, BGP_NO_SNAPSHOT_TEST);
+ pg = BufferGetPage(buf);
pageopaque = (HashPageOpaque) PageGetSpecialPointer(pg);
pageopaque->hasho_prevblkno = InvalidBlockNumber;
pageopaque->hasho_nextblkno = InvalidBlockNumber;
@@ -519,8 +517,7 @@ _hash_expandtable(Relation rel, Buffer metabuf)
_hash_chgbufaccess(rel, metabuf, HASH_NOLOCK, HASH_WRITE);
_hash_checkpage(rel, metabuf, LH_META_PAGE);
- metap = HashPageGetMeta(BufferGetPage(metabuf, NULL, NULL,
- BGP_NO_SNAPSHOT_TEST));
+ metap = HashPageGetMeta(BufferGetPage(metabuf));
/*
* Check to see if split is still needed; someone else might have already
@@ -777,10 +774,10 @@ _hash_splitbucket(Relation rel,
* either bucket.
*/
obuf = _hash_getbuf(rel, start_oblkno, HASH_WRITE, LH_BUCKET_PAGE);
- opage = BufferGetPage(obuf, NULL, NULL, BGP_NO_SNAPSHOT_TEST);
+ opage = BufferGetPage(obuf);
oopaque = (HashPageOpaque) PageGetSpecialPointer(opage);
- npage = BufferGetPage(nbuf, NULL, NULL, BGP_NO_SNAPSHOT_TEST);
+ npage = BufferGetPage(nbuf);
/* initialize the new bucket's primary page */
nopaque = (HashPageOpaque) PageGetSpecialPointer(npage);
@@ -844,7 +841,7 @@ _hash_splitbucket(Relation rel,
_hash_chgbufaccess(rel, nbuf, HASH_WRITE, HASH_NOLOCK);
/* chain to a new overflow page */
nbuf = _hash_addovflpage(rel, metabuf, nbuf);
- npage = BufferGetPage(nbuf, NULL, NULL, BGP_NO_SNAPSHOT_TEST);
+ npage = BufferGetPage(nbuf);
/* we don't need nopaque within the loop */
}
@@ -891,7 +888,7 @@ _hash_splitbucket(Relation rel,
/* Else, advance to next old page */
obuf = _hash_getbuf(rel, oblkno, HASH_WRITE, LH_OVERFLOW_PAGE);
- opage = BufferGetPage(obuf, NULL, NULL, BGP_NO_SNAPSHOT_TEST);
+ opage = BufferGetPage(obuf);
oopaque = (HashPageOpaque) PageGetSpecialPointer(opage);
}