aboutsummaryrefslogtreecommitdiff
path: root/src/backend/access/hash/hash_xlog.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/backend/access/hash/hash_xlog.c')
-rw-r--r--src/backend/access/hash/hash_xlog.c8
1 files changed, 5 insertions, 3 deletions
diff --git a/src/backend/access/hash/hash_xlog.c b/src/backend/access/hash/hash_xlog.c
index 2ccaf469e78..d1c0e6904fc 100644
--- a/src/backend/access/hash/hash_xlog.c
+++ b/src/backend/access/hash/hash_xlog.c
@@ -1234,6 +1234,7 @@ hash_mask(char *pagedata, BlockNumber blkno)
{
Page page = (Page) pagedata;
HashPageOpaque opaque;
+ int pagetype;
mask_page_lsn(page);
@@ -1242,15 +1243,16 @@ hash_mask(char *pagedata, BlockNumber blkno)
opaque = (HashPageOpaque) PageGetSpecialPointer(page);
- if (opaque->hasho_flag & LH_UNUSED_PAGE)
+ pagetype = opaque->hasho_flag & LH_PAGE_TYPE;
+ if (pagetype == LH_UNUSED_PAGE)
{
/*
* Mask everything on a UNUSED page.
*/
mask_page_content(page);
}
- else if ((opaque->hasho_flag & LH_BUCKET_PAGE) ||
- (opaque->hasho_flag & LH_OVERFLOW_PAGE))
+ else if (pagetype == LH_BUCKET_PAGE ||
+ pagetype == LH_OVERFLOW_PAGE)
{
/*
* In hash bucket and overflow pages, it is possible to modify the