Fix some typos
This commit is contained in:
parent
51ae7a0ae5
commit
1eb7bbc6be
|
@ -15,7 +15,7 @@ Test behavior of -maxuploadtarget.
|
||||||
|
|
||||||
* Verify that getdata requests for old blocks (>1week) are dropped
|
* Verify that getdata requests for old blocks (>1week) are dropped
|
||||||
if uploadtarget has been reached.
|
if uploadtarget has been reached.
|
||||||
* Verify that getdata requests for recent blocks are respecteved even
|
* Verify that getdata requests for recent blocks are respected even
|
||||||
if uploadtarget has been reached.
|
if uploadtarget has been reached.
|
||||||
* Verify that the upload counters are reset after 24 hours.
|
* Verify that the upload counters are reset after 24 hours.
|
||||||
'''
|
'''
|
||||||
|
|
|
@ -2077,7 +2077,7 @@ bool CNode::OutboundTargetReached(uint64_t targetSpacing, bool historicalBlockSe
|
||||||
|
|
||||||
if (historicalBlockServingLimit)
|
if (historicalBlockServingLimit)
|
||||||
{
|
{
|
||||||
// keep a large enought buffer to at least relay each block once
|
// keep a large enough buffer to at least relay each block once
|
||||||
uint64_t timeLeftInCycle = GetMaxOutboundTimeLeftInCycle();
|
uint64_t timeLeftInCycle = GetMaxOutboundTimeLeftInCycle();
|
||||||
uint64_t buffer = timeLeftInCycle / targetSpacing * MAX_BLOCK_SIZE;
|
uint64_t buffer = timeLeftInCycle / targetSpacing * MAX_BLOCK_SIZE;
|
||||||
return (buffer >= nMaxOutboundLimit || nMaxOutboundTotalBytesSentInCycle >= nMaxOutboundLimit - buffer);
|
return (buffer >= nMaxOutboundLimit || nMaxOutboundTotalBytesSentInCycle >= nMaxOutboundLimit - buffer);
|
||||||
|
|
|
@ -691,8 +691,8 @@ public:
|
||||||
// in case of no limit, it will always response 0
|
// in case of no limit, it will always response 0
|
||||||
static uint64_t GetOutboundTargetBytesLeft();
|
static uint64_t GetOutboundTargetBytesLeft();
|
||||||
|
|
||||||
//!response the time in second left in the current max outbound cycle
|
//!response the time in seconds left in the current max outbound cycle
|
||||||
// in case of no limit, it will always response 0
|
// in case of no limit, it will always respond with 0
|
||||||
static uint64_t GetMaxOutboundTimeLeftInCycle();
|
static uint64_t GetMaxOutboundTimeLeftInCycle();
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue