From aa16ea5e267d73ec397c805501367cfce34461c0 Mon Sep 17 00:00:00 2001 From: Christine Dodrill Date: Sun, 26 Mar 2017 22:00:47 -0700 Subject: [PATCH] tun2: no connections means no connections --- lib/tun2/server.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/tun2/server.go b/lib/tun2/server.go index b4ae7ff..0ebfdc4 100644 --- a/lib/tun2/server.go +++ b/lib/tun2/server.go @@ -365,7 +365,7 @@ func (s *Server) RoundTrip(req *http.Request) (*http.Response, error) { val, ok := s.domains.Get(req.Host) if ok { conns, ok = val.([]*Connection) - if !ok { + if !ok || len(conns) == 0 { ln.Error(errors.New("no backend connected"), ln.F{ "action": "no_backend_connected", "remote": req.RemoteAddr,