From c4c4f1dad721e71d59b40d0d65163265b8c3baf5 Mon Sep 17 00:00:00 2001 From: Tim Flynn Date: Mon, 14 Nov 2016 21:27:05 -0500 Subject: [PATCH] Ensure governance objects are still valid before relaying --- src/governance.cpp | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/src/governance.cpp b/src/governance.cpp index 691d68075..556a75704 100644 --- a/src/governance.cpp +++ b/src/governance.cpp @@ -551,7 +551,10 @@ void CGovernanceManager::Sync(CNode* pfrom, uint256 nProp) CGovernanceObject& govobj = it->second; - if(govobj.IsSetCachedValid() && (nProp == uint256() || h == nProp)) { + std::string strError; + if(govobj.IsSetCachedValid() && + (nProp == uint256() || h == nProp) && + govobj.IsValidLocally(pCurrentBlockIndex, strError, true)) { // Push the inventory budget proposal message over to the other client pfrom->PushInventory(CInv(MSG_GOVERNANCE_OBJECT, h)); ++nInvCount;