Add whitelistalwaysrelay option

This commit is contained in:
Patick Strateman
2015-11-14 04:46:23 -08:00
parent 420fa8143a
commit 3a964973fe
3 changed files with 13 additions and 1 deletions

View File

@@ -4465,7 +4465,7 @@ bool static ProcessMessage(CNode* pfrom, string strCommand, CDataStream& vRecv,
assert(recentRejects);
recentRejects->insert(tx.GetHash());
if (pfrom->fWhitelisted) {
if (pfrom->fWhitelisted && GetBoolArg("-whitelistalwaysrelay", DEFAULT_WHITELISTALWAYSRELAY)) {
// Always relay transactions received from whitelisted peers, even
// if they were rejected from the mempool, allowing the node to
// function as a gateway for nodes hidden behind it.