From 95743085457314b4b0e8115133a3aaef19e494de Mon Sep 17 00:00:00 2001 From: Arceliar Date: Sun, 24 May 2020 17:24:50 -0500 Subject: [PATCH] have the peer delay setting a max buffer size, in case things have unblocked in the mean time --- src/yggdrasil/peer.go | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/src/yggdrasil/peer.go b/src/yggdrasil/peer.go index 4463bc6d..ce120b8d 100644 --- a/src/yggdrasil/peer.go +++ b/src/yggdrasil/peer.go @@ -303,10 +303,12 @@ func (p *peer) _handleIdle() { func (p *peer) dropFromQueue(from phony.Actor, seq uint64) { p.Act(from, func() { - if seq == p.seq { - p.drop = true - p.max = p.queue.size + streamMsgSize - } + p.Act(nil, func() { + if seq == p.seq { + p.drop = true + p.max = p.queue.size + streamMsgSize + } + }) }) }