From b604a014125b256bf0660e0140846736f46dbbd8 Mon Sep 17 00:00:00 2001 From: Peter Bushnell Date: Thu, 23 Jun 2022 10:49:30 +0100 Subject: [PATCH] Restore guard on CalculateOwnerRewards --- src/masternodes/mn_checks.cpp | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/masternodes/mn_checks.cpp b/src/masternodes/mn_checks.cpp index 0b959b7679..cb05ccc812 100644 --- a/src/masternodes/mn_checks.cpp +++ b/src/masternodes/mn_checks.cpp @@ -1565,7 +1565,9 @@ class CCustomTxApplyVisitor : public CCustomTxVisitor CDataStructureV0 liveKey{AttributeTypes::Live, ParamIDs::Economy, economyKey}; auto balances = attributes->GetValue(liveKey, CBalances{}); - CalculateOwnerRewards(obj.owner); + if (height >= static_cast(consensus.FortCanningCrunchHeight)) { + CalculateOwnerRewards(obj.owner); + } if (obj.withdraw) {