mirror of
https://github.com/cwinfo/yggdrasil-go.git
synced 2025-07-14 21:28:57 +00:00
Only stop timers if they are running
This commit is contained in:
@ -75,8 +75,12 @@ func (m *Multicast) Start() error {
|
||||
// Stop is not implemented for multicast yet.
|
||||
func (m *Multicast) Stop() error {
|
||||
m.isOpen = false
|
||||
m.announcer.Stop()
|
||||
m.platformhandler.Stop()
|
||||
if m.announcer != nil {
|
||||
m.announcer.Stop()
|
||||
}
|
||||
if m.platformhandler != nil {
|
||||
m.platformhandler.Stop()
|
||||
}
|
||||
m.sock.Close()
|
||||
return nil
|
||||
}
|
||||
|
Reference in New Issue
Block a user