mirror of
https://github.com/shizunge/endlessh-go.git
synced 2026-08-07 07:15:02 +00:00
Move to above line 195. Avoid interrupt checking connPorts and using connPorts.
As suggested by @shizunge
This commit is contained in:
@@ -190,6 +190,9 @@ func main() {
|
||||
})
|
||||
clients := startSending(*maxClients, *bannerMaxLength, records)
|
||||
|
||||
// Start the healthcheck listener.
|
||||
health.StartListener(*healthcheckHost, *healthcheckPort)
|
||||
|
||||
interval := time.Duration(*intervalMs) * time.Millisecond
|
||||
// Listen for incoming connections.
|
||||
if *connType == "tcp6" && *connHost == "0.0.0.0" {
|
||||
@@ -198,7 +201,6 @@ func main() {
|
||||
if len(connPorts) == 0 {
|
||||
connPorts = append(connPorts, defaultPort)
|
||||
}
|
||||
health.StartListener(*healthcheckHost, *healthcheckPort)
|
||||
for _, connPort := range connPorts {
|
||||
startAccepting(*maxClients, *connType, *connHost, connPort, interval, clients, records, *proxyProtocolEnabled, *proxyProtocolReadHeaderTimeout)
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user