Skip to content

Commit 97c19e6

Browse files
committed
Fix gin_desc routine to match the WAL format.
In the GIN incomplete-splits patch, I used BlockIdDatas to store the block number of left and right children, when inserting a downlink after a split to an internal page posting list page. But gin_desc thought they were stored as BlockNumbers.
1 parent da8a716 commit 97c19e6

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

src/backend/access/rmgrdesc/gindesc.c

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -56,9 +56,9 @@ gin_desc(StringInfo buf, uint8 xl_info, char *rec)
5656
BlockNumber leftChildBlkno;
5757
BlockNumber rightChildBlkno;
5858

59-
memcpy(&leftChildBlkno, payload, sizeof(BlockNumber));
60-
payload += sizeof(BlockNumber);
61-
memcpy(&rightChildBlkno, payload, sizeof(BlockNumber));
59+
leftChildBlkno = BlockIdGetBlockNumber((BlockId) payload);
60+
payload += sizeof(BlockIdData);
61+
rightChildBlkno = BlockIdGetBlockNumber((BlockId) payload);
6262
payload += sizeof(BlockNumber);
6363
appendStringInfo(buf, " children: %u/%u",
6464
leftChildBlkno, rightChildBlkno);

0 commit comments

Comments
 (0)
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy