1
0
mirror of https://github.com/bgp/stayrtr.git synced 2024-05-06 15:54:54 +00:00

Fix client.sendLoop possibly leaking/CPU burning

Basically, until now it was not possible for it to actually
exit since the break only breaks the for loop it's connected in
This commit is contained in:
Ben Cartwright-Cox
2023-02-21 22:11:43 +00:00
parent 19ca7b27e9
commit 6e4c533e8a

View File

@ -802,7 +802,7 @@ func (c *Client) sendLoop() {
case pdu := <-c.transmits:
c.wr.Write(pdu.Bytes())
case <-c.quit:
break
return
}
}
}