From a551686d37c08e485f4576dc35dc4265f0c6eee6 Mon Sep 17 00:00:00 2001 From: Jakob Borg Date: Fri, 1 Apr 2016 07:24:04 +0000 Subject: [PATCH] lib/discovery: Receiving a new announcement should be non-blocking Pretty sure the intention of the select was for it to be non-blocking. Not that it will matter almost ever. --- lib/discover/local.go | 3 +++ 1 file changed, 3 insertions(+) diff --git a/lib/discover/local.go b/lib/discover/local.go index 9f2944b0e..87a7fd089 100644 --- a/lib/discover/local.go +++ b/lib/discover/local.go @@ -179,8 +179,11 @@ func (c *localClient) recvAnnouncements(b beacon.Interface) { } if newDevice { + // Force a transmit to announce ourselves, if we are ready to do + // so right away. select { case c.forcedBcastTick <- time.Now(): + default: } } }