tun2: loop forever at the foot of HandleConn
This commit is contained in:
parent
1827d19e84
commit
56fc4f89ba
|
@ -361,6 +361,7 @@ func (s *Server) HandleConn(c net.Conn, isKCP bool) {
|
|||
ticker := time.NewTicker(5 * time.Second)
|
||||
defer ticker.Stop()
|
||||
|
||||
for {
|
||||
select {
|
||||
case <-ticker.C:
|
||||
err := connection.Ping()
|
||||
|
@ -409,6 +410,7 @@ func (s *Server) HandleConn(c net.Conn, isKCP bool) {
|
|||
return
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
func (s *Server) RoundTrip(req *http.Request) (*http.Response, error) {
|
||||
var conns []*Connection
|
||||
|
|
Loading…
Reference in New Issue