Don't panic if changing interest fills the write buffer
This was the old behaviour, years ago. I don't know why it's suddenly being triggered lately.
This commit is contained in:
parent
c3622dea3d
commit
8ac9ea890e
|
@ -272,7 +272,7 @@ func (p *Peer) maybeUpdateActualRequestState() {
|
||||||
func (p *Peer) applyRequestState(next desiredRequestState) {
|
func (p *Peer) applyRequestState(next desiredRequestState) {
|
||||||
current := &p.requestState
|
current := &p.requestState
|
||||||
if !p.setInterested(next.Interested) {
|
if !p.setInterested(next.Interested) {
|
||||||
panic("insufficient write buffer")
|
return
|
||||||
}
|
}
|
||||||
more := true
|
more := true
|
||||||
requestHeap := binheap.FromSlice(next.Requests.requestIndexes, next.Requests.lessByValue)
|
requestHeap := binheap.FromSlice(next.Requests.requestIndexes, next.Requests.lessByValue)
|
||||||
|
|
Loading…
Reference in New Issue