mirror of
https://github.com/dashpay/dash.git
synced 2024-12-26 04:22:55 +01:00
net: add nSendBufferMaxSize/nReceiveFloodSize to CConnection::Options
This commit is contained in:
parent
a19553b992
commit
fa2f8bc47f
@ -1522,6 +1522,8 @@ bool AppInit2(boost::thread_group& threadGroup, CScheduler& scheduler)
|
||||
connOptions.nMaxOutbound = std::min(MAX_OUTBOUND_CONNECTIONS, connOptions.nMaxConnections);
|
||||
connOptions.nBestHeight = chainActive.Height();
|
||||
connOptions.uiInterface = &uiInterface;
|
||||
connOptions.nSendBufferMaxSize = 1000*GetArg("-maxsendbuffer", DEFAULT_MAXSENDBUFFER);
|
||||
connOptions.nReceiveFloodSize = 1000*GetArg("-maxreceivebuffer", DEFAULT_MAXRECEIVEBUFFER);
|
||||
|
||||
if(!connman.Start(threadGroup, scheduler, strNodeError, connOptions))
|
||||
return InitError(strNodeError);
|
||||
|
@ -2063,8 +2063,8 @@ bool CConnman::Start(boost::thread_group& threadGroup, CScheduler& scheduler, st
|
||||
nMaxConnections = connOptions.nMaxConnections;
|
||||
nMaxOutbound = std::min((connOptions.nMaxOutbound), nMaxConnections);
|
||||
|
||||
nSendBufferMaxSize = 1000*GetArg("-maxsendbuffer", DEFAULT_MAXSENDBUFFER);
|
||||
nReceiveFloodSize = 1000*GetArg("-maxreceivebuffer", DEFAULT_MAXRECEIVEBUFFER);
|
||||
nSendBufferMaxSize = connOptions.nSendBufferMaxSize;
|
||||
nReceiveFloodSize = connOptions.nSendBufferMaxSize;
|
||||
|
||||
SetBestHeight(connOptions.nBestHeight);
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user