From 366379781599fe64c822cdb1fd93e810d3c582bc Mon Sep 17 00:00:00 2001 From: Wendi Yu Date: Tue, 12 May 2020 10:14:37 -0600 Subject: [PATCH] Reduce logspam from node with no peers Signed-off-by: Wendi Yu --- ipn/local.go | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/ipn/local.go b/ipn/local.go index 7edd12470..85e46378a 100644 --- a/ipn/local.go +++ b/ipn/local.go @@ -567,7 +567,9 @@ func (b *LocalBackend) parseWgStatus(s *wgengine.Status) EngineStatus { rx += p.RxBytes tx += p.TxBytes } - b.logf("v%v peers: %v", version.LONG, strings.Join(ss, " ")) + if len(ss) != 0 { + b.logf("v%v peers: %v", version.LONG, strings.Join(ss, " ")) + } return EngineStatus{ RBytes: rx, WBytes: tx,