Style: code style

This commit is contained in:
Dreamacro
2021-04-26 20:42:17 +08:00
parent 16a6d409d9
commit 682e65cb54
3 changed files with 7 additions and 4 deletions

View File

@ -48,7 +48,7 @@ func NewTProxy(addr string) (*TProxyListener, error) {
}
continue
}
go rl.handleRedir(c)
go rl.handleTProxy(c)
}
}()
@ -64,7 +64,7 @@ func (l *TProxyListener) Address() string {
return l.address
}
func (l *TProxyListener) handleRedir(conn net.Conn) {
func (l *TProxyListener) handleTProxy(conn net.Conn) {
target := socks5.ParseAddrToSocksAddr(conn.LocalAddr())
conn.(*net.TCPConn).SetKeepAlive(true)
tunnel.Add(inbound.NewSocket(target, conn, C.TPROXY))