diff options
author | Felföldi Zsolt <zsfelfoldi@gmail.com> | 2017-08-09 00:31:08 +0800 |
---|---|---|
committer | Péter Szilágyi <peterke@gmail.com> | 2017-08-09 00:31:08 +0800 |
commit | fff6e03a792b0e0a84943e2c3764c39b2840458a (patch) | |
tree | 37d811da67038ac2bacdf1b1595a8f867b46eba0 /les/flowcontrol | |
parent | d375193797e8198a82c6a1796064ffb289c6956e (diff) | |
download | dexon-fff6e03a792b0e0a84943e2c3764c39b2840458a.tar.gz dexon-fff6e03a792b0e0a84943e2c3764c39b2840458a.tar.zst dexon-fff6e03a792b0e0a84943e2c3764c39b2840458a.zip |
les: fix megacheck warnings (#14941)
* les: fix megacheck warnings
* les: fixed testGetProofs
Diffstat (limited to 'les/flowcontrol')
-rw-r--r-- | les/flowcontrol/control.go | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/les/flowcontrol/control.go b/les/flowcontrol/control.go index e40e69346..d50eb809c 100644 --- a/les/flowcontrol/control.go +++ b/les/flowcontrol/control.go @@ -157,9 +157,7 @@ func (peer *ServerNode) QueueRequest(reqID, maxCost uint64) { peer.bufEstimate -= maxCost peer.sumCost += maxCost - if reqID >= 0 { - peer.pending[reqID] = peer.sumCost - } + peer.pending[reqID] = peer.sumCost } // GotReply adjusts estimated buffer value according to the value included in |