Skip to content

Commit e2b2dee

Browse files
committed
PGPRO-427: Add header size into WAL record start pointer
1 parent 6e0f5bb commit e2b2dee

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

src/parsexlog.c

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -179,6 +179,9 @@ doExtractPageMap(void *arg)
179179
/* Adjust next record position */
180180
XLogSegNoOffsetToRecPtr(extract_arg->private_data.xlogsegno, 0,
181181
extract_arg->startpoint);
182+
/* Skip over the page header */
183+
extract_arg->startpoint += SizeOfXLogLongPHD;
184+
182185
continue;
183186
}
184187

@@ -283,6 +286,8 @@ extractPageMap(const char *archivedir, XLogRecPtr startpoint, TimeLineID tli,
283286
if (nextSegNoToRead > endSegNo)
284287
break;
285288
XLogSegNoOffsetToRecPtr(nextSegNoToRead, 0, startpoint);
289+
/* Skip over the page header */
290+
startpoint += SizeOfXLogLongPHD;
286291

287292
threads_need++;
288293
}

0 commit comments

Comments
 (0)