device: tie encryption queue lifetime to the peers that write to it
Signed-off-by: Josh Bleecher Snyder <josh@tailscale.com>
This commit is contained in:
committed by
Jason A. Donenfeld
parent
4846070322
commit
8a374a35a0
@@ -291,8 +291,6 @@ func (peer *Peer) StagePacket(elem *QueueOutboundElement) {
|
||||
}
|
||||
|
||||
func (peer *Peer) SendStagedPackets() {
|
||||
peer.device.queue.encryption.wg.Add(1)
|
||||
defer peer.device.queue.encryption.wg.Done()
|
||||
top:
|
||||
if len(peer.queue.staged) == 0 || !peer.device.isUp.Get() {
|
||||
return
|
||||
|
||||
Reference in New Issue
Block a user