Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit 9804b79

Browse files
committed
bugfix: uninterrupt WAL reading
1 parent 8c5e8e0 commit 9804b79

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

src/parsexlog.c

+4
Original file line numberDiff line numberDiff line change
@@ -793,6 +793,10 @@ SimpleXLogPageRead(XLogReaderState *xlogreader, XLogRecPtr targetPagePtr,
793793
private_data = (XLogPageReadPrivate *) xlogreader->private_data;
794794
targetPageOff = targetPagePtr % private_data->xlog_seg_size;
795795

796+
if (interrupted)
797+
elog(ERROR, "Thread [%d]: Interrupted during WAL reading",
798+
private_data->thread_num);
799+
796800
/*
797801
* See if we need to switch to a new segment because the requested record
798802
* is not in the currently open one.

0 commit comments

Comments
 (0)