Skip to content

Commit 7c0cf2e

Browse files
committed
also fix possible overflow in MtmMinRecoveryLag
1 parent a0020e7 commit 7c0cf2e

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

contrib/mmts/multimaster.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2104,7 +2104,7 @@ void MtmCheckRecoveryCaughtUp(int nodeId, lsn_t slotLSN)
21042104
if (MtmIsRecoveredNode(nodeId)) {
21052105
lsn_t walLSN = GetXLogInsertRecPtr();
21062106
if (!BIT_CHECK(Mtm->originLockNodeMask, nodeId-1)
2107-
&& slotLSN + MtmMinRecoveryLag * 1024 > walLSN)
2107+
&& slotLSN + (long64) MtmMinRecoveryLag * 1024 > walLSN)
21082108
{
21092109
/*
21102110
* Wal sender almost caught up.

0 commit comments

Comments
 (0)