From cf333b5f09ccd4af0e63edd7cd4cf7620c3e4b2a Mon Sep 17 00:00:00 2001 From: Jeff Emershaw Date: Thu, 15 May 2025 21:34:18 +0000 Subject: [PATCH] handling a nil panic pointer causing a node to be removed --- hscontrol/poll.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/hscontrol/poll.go b/hscontrol/poll.go index 763ab85b..71ee9a8e 100644 --- a/hscontrol/poll.go +++ b/hscontrol/poll.go @@ -200,7 +200,7 @@ func (m *mapSession) serveLongPoll() { // in principal, it will be removed, but the client rapidly // reconnects, the channel might be of another connection. // In that case, it is not closed and the node is still online. - if m.h.nodeNotifier.RemoveNode(m.node.ID, m.ch) { + if m.node != nil && m.h.nodeNotifier.RemoveNode(m.node.ID, m.ch) { // Failover the node's routes if any. m.h.updateNodeOnlineStatus(false, m.node)