aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorHeikki Linnakangas <heikki.linnakangas@iki.fi>2013-11-28 21:54:49 +0200
committerHeikki Linnakangas <heikki.linnakangas@iki.fi>2013-11-28 21:57:42 +0200
commit97c19e6c38ebc5e300539f6985ef3e05398c8f46 (patch)
tree21bd54550016c2e8d36fca12a24371b7c5ce61e0 /src
parentda8a7160893c463690146c7b30220b90c593ec15 (diff)
downloadpostgresql-97c19e6c38ebc5e300539f6985ef3e05398c8f46.tar.gz
postgresql-97c19e6c38ebc5e300539f6985ef3e05398c8f46.zip
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.
Diffstat (limited to 'src')
-rw-r--r--src/backend/access/rmgrdesc/gindesc.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/backend/access/rmgrdesc/gindesc.c b/src/backend/access/rmgrdesc/gindesc.c
index 72d60bf8d32..3675e1ec5d8 100644
--- a/src/backend/access/rmgrdesc/gindesc.c
+++ b/src/backend/access/rmgrdesc/gindesc.c
@@ -56,9 +56,9 @@ gin_desc(StringInfo buf, uint8 xl_info, char *rec)
BlockNumber leftChildBlkno;
BlockNumber rightChildBlkno;
- memcpy(&leftChildBlkno, payload, sizeof(BlockNumber));
- payload += sizeof(BlockNumber);
- memcpy(&rightChildBlkno, payload, sizeof(BlockNumber));
+ leftChildBlkno = BlockIdGetBlockNumber((BlockId) payload);
+ payload += sizeof(BlockIdData);
+ rightChildBlkno = BlockIdGetBlockNumber((BlockId) payload);
payload += sizeof(BlockNumber);
appendStringInfo(buf, " children: %u/%u",
leftChildBlkno, rightChildBlkno);