mirror of
https://github.com/dashpay/dash.git
synced 2024-12-25 20:12:57 +01:00
Don'd send SENDXXX messages to fMasternode connections (#3537)
And respect a received QSENDRECSIGS no matter if fMasternode or not. We assume that fMasternode peers won't send QSENDRECSIGS from now on.
This commit is contained in:
parent
0fa058deb5
commit
737ed479bc
@ -730,7 +730,7 @@ void CSigningManager::ProcessRecoveredSig(NodeId nodeId, const CRecoveredSig& re
|
|||||||
|
|
||||||
CInv inv(MSG_QUORUM_RECOVERED_SIG, recoveredSig.GetHash());
|
CInv inv(MSG_QUORUM_RECOVERED_SIG, recoveredSig.GetHash());
|
||||||
g_connman->ForEachNode([&](CNode* pnode) {
|
g_connman->ForEachNode([&](CNode* pnode) {
|
||||||
if (pnode->nVersion >= LLMQS_PROTO_VERSION && pnode->fSendRecSigs && !pnode->fMasternode) {
|
if (pnode->nVersion >= LLMQS_PROTO_VERSION && pnode->fSendRecSigs) {
|
||||||
pnode->PushInventory(inv);
|
pnode->PushInventory(inv);
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
@ -2331,7 +2331,7 @@ bool static ProcessMessage(CNode* pfrom, const std::string& strCommand, CDataStr
|
|||||||
connman->PushMessage(pfrom, msgMaker.Make(NetMsgType::SENDHEADERS));
|
connman->PushMessage(pfrom, msgMaker.Make(NetMsgType::SENDHEADERS));
|
||||||
}
|
}
|
||||||
|
|
||||||
if (pfrom->nVersion >= SHORT_IDS_BLOCKS_VERSION) {
|
if (pfrom->nVersion >= SHORT_IDS_BLOCKS_VERSION && !pfrom->fMasternode) {
|
||||||
// Tell our peer we are willing to provide version-1 cmpctblocks
|
// Tell our peer we are willing to provide version-1 cmpctblocks
|
||||||
// However, we do not request new block announcements using
|
// However, we do not request new block announcements using
|
||||||
// cmpctblock messages.
|
// cmpctblock messages.
|
||||||
@ -2351,7 +2351,7 @@ bool static ProcessMessage(CNode* pfrom, const std::string& strCommand, CDataStr
|
|||||||
pfrom->fSendDSQueue = true;
|
pfrom->fSendDSQueue = true;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (pfrom->nVersion >= LLMQS_PROTO_VERSION) {
|
if (pfrom->nVersion >= LLMQS_PROTO_VERSION && !pfrom->fMasternode) {
|
||||||
// Tell our peer that we're interested in plain LLMQ recovered signatures.
|
// Tell our peer that we're interested in plain LLMQ recovered signatures.
|
||||||
// Otherwise the peer would only announce/send messages resulting from QRECSIG,
|
// Otherwise the peer would only announce/send messages resulting from QRECSIG,
|
||||||
// e.g. InstantSend locks or ChainLocks. SPV nodes should not send this message
|
// e.g. InstantSend locks or ChainLocks. SPV nodes should not send this message
|
||||||
@ -2359,7 +2359,7 @@ bool static ProcessMessage(CNode* pfrom, const std::string& strCommand, CDataStr
|
|||||||
connman->PushMessage(pfrom, msgMaker.Make(NetMsgType::QSENDRECSIGS, true));
|
connman->PushMessage(pfrom, msgMaker.Make(NetMsgType::QSENDRECSIGS, true));
|
||||||
}
|
}
|
||||||
|
|
||||||
if (gArgs.GetBoolArg("-watchquorums", llmq::DEFAULT_WATCH_QUORUMS)) {
|
if (gArgs.GetBoolArg("-watchquorums", llmq::DEFAULT_WATCH_QUORUMS) && !pfrom->fMasternode) {
|
||||||
connman->PushMessage(pfrom, msgMaker.Make(NetMsgType::QWATCH));
|
connman->PushMessage(pfrom, msgMaker.Make(NetMsgType::QWATCH));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user