Remove first byte wait when tcp catches all
This commit is contained in:
parent
518a37e776
commit
c1dc783512
5 changed files with 155 additions and 14 deletions
|
@ -27,6 +27,11 @@ type Router struct {
|
|||
func (r *Router) ServeTCP(conn net.Conn) {
|
||||
// FIXME -- Check if ProxyProtocol changes the first bytes of the request
|
||||
|
||||
if r.catchAllNoTLS != nil && len(r.routingTable) == 0 && r.httpsHandler == nil {
|
||||
r.catchAllNoTLS.ServeTCP(conn)
|
||||
return
|
||||
}
|
||||
|
||||
br := bufio.NewReader(conn)
|
||||
serverName, tls, peeked := clientHelloServerName(br)
|
||||
if !tls {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue