mirror of
https://github.com/postgres/postgres.git
synced 2026-03-03 22:00:57 -05:00
Fix checking for recovery state in WaitForLSN()
We only need to do it for WAIT_LSN_TYPE_REPLAY. WAIT_LSN_TYPE_FLUSH can work for both primary and follower.
This commit is contained in:
parent
07961ef866
commit
7742f99a02
1 changed files with 1 additions and 1 deletions
|
|
@ -347,7 +347,7 @@ WaitForLSN(WaitLSNType lsnType, XLogRecPtr targetLSN, int64 timeout)
|
|||
currentLSN = GetFlushRecPtr(NULL);
|
||||
|
||||
/* Check that recovery is still in-progress */
|
||||
if (!RecoveryInProgress())
|
||||
if (lsnType == WAIT_LSN_TYPE_REPLAY && !RecoveryInProgress())
|
||||
{
|
||||
/*
|
||||
* Recovery was ended, but check if target LSN was already
|
||||
|
|
|
|||
Loading…
Reference in a new issue