Separate the window sentence from the wrapped error so a bad certificate file is not reported as a key mismatch.

Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
2026-10-07 15:01:38 +02:00
co-authored by Cursor
parent a405048f23
commit e642b24be0
17 changed files with 842 additions and 742 deletions
+9 -1
View File
@@ -93,6 +93,10 @@ func (s *Station) noteDownLocked(now time.Time, dial bool) {
}
func (s *Station) endFatal(msg string, log bool) {
s.endFatalCause(msg, nil, log)
}
func (s *Station) endFatalCause(msg string, cause error, log bool) {
s.mu.Lock()
defer s.mu.Unlock()
if s.fatal != "" {
@@ -107,7 +111,11 @@ func (s *Station) endFatal(msg string, log bool) {
if log {
s.up = false
s.outage = true
s.writeLog(now, oneLine(msg))
line := oneLine(msg)
if cause != nil {
line += ": " + oneLine(cause.Error())
}
s.writeLog(now, line)
}
s.publish()
}