fix https server crash
This commit is contained in:
parent
c28e712560
commit
821ab4d3b7
5
node.go
5
node.go
@ -5,8 +5,6 @@ import (
|
||||
"net/url"
|
||||
"strconv"
|
||||
"strings"
|
||||
|
||||
"github.com/go-log/log"
|
||||
)
|
||||
|
||||
// Node is a proxy node, mainly used to construct a proxy chain.
|
||||
@ -89,8 +87,5 @@ func Can(action string, addr string, whitelist, blacklist *Permissions) bool {
|
||||
return false
|
||||
}
|
||||
|
||||
if Debug {
|
||||
log.Logf("Can action: %s, host: %s, port %d", action, host, port)
|
||||
}
|
||||
return whitelist.Can(action, host, port) && !blacklist.Can(action, host, port)
|
||||
}
|
||||
|
2
tls.go
2
tls.go
@ -41,7 +41,7 @@ func TLSListener(addr string, config *tls.Config) (Listener, error) {
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
return &tlsListener{tcpKeepAliveListener{ln.(*net.TCPListener)}}, nil
|
||||
return &tlsListener{ln}, nil
|
||||
}
|
||||
|
||||
// Wrap a net.Conn into a client tls connection, performing any
|
||||
|
Loading…
Reference in New Issue
Block a user