From 387ae9ea6c78321f2c7c23693d0ab7ec6d2ea376 Mon Sep 17 00:00:00 2001 From: Neil Alexander Date: Tue, 25 Sep 2018 18:05:57 +0100 Subject: [PATCH] Only replace call name with interface prefix when interface is set --- src/yggdrasil/tcp.go | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/src/yggdrasil/tcp.go b/src/yggdrasil/tcp.go index 4c71045..4850899 100644 --- a/src/yggdrasil/tcp.go +++ b/src/yggdrasil/tcp.go @@ -112,7 +112,10 @@ func (iface *tcpInterface) listener() { // This all happens in a separate goroutine that it spawns. func (iface *tcpInterface) call(saddr string, socksaddr *string, sintf string) { go func() { - callname := fmt.Sprintf("%s/%s", saddr, sintf) + callname := saddr + if sintf != "" { + callname = fmt.Sprintf("%s/%s", saddr, sintf) + } quit := false iface.mutex.Lock() if _, isIn := iface.calls[callname]; isIn {