Skip to content

Commit ec1dc9b

Browse files
author
Antonin Houska
committed
Make sure that reading of WAL record starts after page header.
1 parent cdb4d53 commit ec1dc9b

File tree

1 file changed

+7
-0
lines changed

1 file changed

+7
-0
lines changed

src/wbfilter.c

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -78,6 +78,13 @@ WbFProcessWalDataBlock(ReplMessage* msg, FilterData* fl, XLogRecPtr *retryPos)
7878

7979
msg->nextPageBoundary += XLOG_BLCKSZ;
8080

81+
/*
82+
* Adjust recordStart so it does not point to the beginning of the
83+
* page.
84+
*/
85+
if (fl->recordStart == headerPos)
86+
fl->recordStart = msg->dataPtr;
87+
8188
switch (fl->state)
8289
{
8390
case FS_SYNCHRONIZING:

0 commit comments

Comments
 (0)