lib/connections: Don't panic on removed device (fixes #5299) (#5300)

This commit is contained in:
Simon Frei 2018-10-30 10:34:19 +01:00 committed by Jakob Borg
parent b1acc37c16
commit 01ade9c8ae
1 changed files with 3 additions and 1 deletions

View File

@ -245,7 +245,9 @@ next:
deviceCfg, ok := s.cfg.Device(remoteID)
if !ok {
panic("bug: unknown device should already have been rejected")
l.Infof("Device %s removed from config during connection attempt at %s", remoteID, c)
c.Close()
continue
}
// Verify the name on the certificate. By default we set it to