mirror of
https://github.com/yggdrasil-network/yggdrasil-go.git
synced 2024-12-22 16:07:31 +00:00
Fix PPROFLISTEN
This commit is contained in:
parent
3d15da34ad
commit
6b6cd0bed5
@ -12,6 +12,8 @@ func init() {
|
|||||||
envVarName := "PPROFLISTEN"
|
envVarName := "PPROFLISTEN"
|
||||||
if hostPort := os.Getenv(envVarName); hostPort != "" {
|
if hostPort := os.Getenv(envVarName); hostPort != "" {
|
||||||
fmt.Fprintf(os.Stderr, "DEBUG: Starting pprof on %s\n", hostPort)
|
fmt.Fprintf(os.Stderr, "DEBUG: Starting pprof on %s\n", hostPort)
|
||||||
go fmt.Println(http.ListenAndServe(hostPort, nil))
|
go func() {
|
||||||
|
fmt.Fprintf(os.Stderr, "DEBUG: %s", http.ListenAndServe(hostPort, nil))
|
||||||
|
}()
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user