Browse Source

don't trickle for whitelisted nodes

tags/v0.15.1
Ruben de Vries 6 years ago
parent
commit
fc720207e0
2 changed files with 7 additions and 2 deletions
  1. 6
    1
      src/main.h
  2. 1
    1
      src/net.cpp

+ 6
- 1
src/main.h View File

@@ -177,7 +177,12 @@ bool LoadBlockIndex();
void UnloadBlockIndex();
/** Process protocol messages received from a given node */
bool ProcessMessages(CNode* pfrom);
/** Send queued protocol messages to be sent to a give node */
/**
* Send queued protocol messages to be sent to a give node.
*
* @param[in] pto The node which we are sending messages to.
* @param[in] fSendTrickle When true send the trickled data, otherwise trickle the data until true.
*/
bool SendMessages(CNode* pto, bool fSendTrickle);
/** Run an instance of the script checking thread */
void ThreadScriptCheck();

+ 1
- 1
src/net.cpp View File

@@ -1406,7 +1406,7 @@ void ThreadMessageHandler()
{
TRY_LOCK(pnode->cs_vSend, lockSend);
if (lockSend)
g_signals.SendMessages(pnode, pnode == pnodeTrickle);
g_signals.SendMessages(pnode, pnode == pnodeTrickle || pnode->fWhitelisted);
}
boost::this_thread::interruption_point();
}

Loading…
Cancel
Save