Debug some issues with the state machine that tracks idle connections in link.go

This commit is contained in:
Arceliar 2019-02-15 19:35:10 -06:00
parent 2ba427a737
commit 6f0bbbfb98
2 changed files with 19 additions and 8 deletions

View file

@ -780,6 +780,7 @@ func (t *switchTable) doWorker() {
t.queues.bufs = make(map[string]switch_buffer) // Packets per PacketStreamID (string)
idle := make(map[switchPort]struct{}) // this is to deduplicate things
for {
t.core.log.Debugf("Switch state: idle = %d, buffers = %d", len(idle), len(t.queues.bufs))
select {
case bytes := <-t.packetIn:
// Try to send it somewhere (or drop it if it's corrupt or at a dead end)