simplify how blocking is detected and packets are dequeued

This commit is contained in:
Arceliar 2020-05-27 18:53:14 -05:00
parent 38dcbb1e2f
commit 1df305d31c
3 changed files with 11 additions and 22 deletions

View file

@ -270,14 +270,14 @@ func (intf *routerInterface) out(bss [][]byte) {
intf.router._handlePacket(bs)
}
})
//intf.router.peer.Act(nil, intf.router.peer._handleIdle)
// This should now immediately make the peer idle again
// So the self-peer shouldn't end up buffering anything
// We let backpressure act as a throttle instead
intf.router.peer._handleIdle()
}
func (intf *routerInterface) linkOut(_ []byte) {}
func (intf *routerInterface) notifyQueued(seq uint64) {}
func (intf *routerInterface) close() {}
func (intf *routerInterface) name() string { return "(self)" }