5
0
mirror of https://github.com/cwinfo/yggdrasil-go.git synced 2024-11-25 21:51:38 +00:00

WIP close the ironwood PacketConn when shutting down

This commit is contained in:
Arceliar 2021-05-08 12:31:26 -05:00
parent b4224aa02d
commit ed85cf08f2

View File

@ -175,6 +175,7 @@ func (c *Core) Stop() {
// This function is unsafe and should only be ran by the core actor. // This function is unsafe and should only be ran by the core actor.
func (c *Core) _stop() { func (c *Core) _stop() {
c.PacketConn.Close()
c.log.Infoln("Stopping...") c.log.Infoln("Stopping...")
if c.addPeerTimer != nil { if c.addPeerTimer != nil {
c.addPeerTimer.Stop() c.addPeerTimer.Stop()