mirror of
https://github.com/zr-hebo/sniffer-agent.git
synced 2025-08-11 17:11:06 +08:00
fix bug of set port
This commit is contained in:
@@ -3,6 +3,7 @@ package communicator
|
||||
import (
|
||||
"flag"
|
||||
"net/http"
|
||||
"strconv"
|
||||
"time"
|
||||
|
||||
_ "net/http/pprof"
|
||||
@@ -19,7 +20,7 @@ func init() {
|
||||
|
||||
func Server() {
|
||||
server := &http.Server{
|
||||
Addr: ":" + string(communicatePort),
|
||||
Addr: ":" + strconv.Itoa(communicatePort),
|
||||
Handler: mux.NewRouter(),
|
||||
IdleTimeout: time.Second * 5,
|
||||
}
|
||||
|
Reference in New Issue
Block a user