From 8f6ebbd3e24b1df2cb2f4f1f4fd227d53adc1e3a Mon Sep 17 00:00:00 2001 From: Derrick Hammer Date: Sun, 7 Jan 2024 05:31:24 -0500 Subject: [PATCH] fix: nil pointer reference --- service/p2p.go | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/service/p2p.go b/service/p2p.go index 6cba975..c4cb00f 100644 --- a/service/p2p.go +++ b/service/p2p.go @@ -157,7 +157,8 @@ func (p *P2PImpl) ConnectToNode(connectionUris []*url.URL, retried bool) error { reconnectDelay := p.reconnectDelay.GetInt(idString) if reconnectDelay == nil { - *reconnectDelay = 1 + delay := 1 + reconnectDelay = &delay } if id.Equals(p.localNodeID) {