summaryrefslogtreecommitdiffstats
path: root/vendor/github.com/google/gops/agent/agent.go
diff options
context:
space:
mode:
authorWim <wim@42.be>2021-03-20 22:40:23 +0100
committerGitHub <noreply@github.com>2021-03-20 22:40:23 +0100
commitee5d9b43b54a3becf3cb4025198f24608d35500d (patch)
treedd3614db7423da52f5a71da3001e48d1e4195ea1 /vendor/github.com/google/gops/agent/agent.go
parent3a8857c8c9efb2c67fb8c175f31d2b9c617b771b (diff)
downloadmatterbridge-msglm-ee5d9b43b54a3becf3cb4025198f24608d35500d.tar.gz
matterbridge-msglm-ee5d9b43b54a3becf3cb4025198f24608d35500d.tar.bz2
matterbridge-msglm-ee5d9b43b54a3becf3cb4025198f24608d35500d.zip
Update vendor (#1414)
Diffstat (limited to 'vendor/github.com/google/gops/agent/agent.go')
-rw-r--r--vendor/github.com/google/gops/agent/agent.go3
1 files changed, 2 insertions, 1 deletions
diff --git a/vendor/github.com/google/gops/agent/agent.go b/vendor/github.com/google/gops/agent/agent.go
index 441814c9..80be4bb6 100644
--- a/vendor/github.com/google/gops/agent/agent.go
+++ b/vendor/github.com/google/gops/agent/agent.go
@@ -16,6 +16,7 @@ import (
"net"
"os"
gosignal "os/signal"
+ "path/filepath"
"runtime"
"runtime/debug"
"runtime/pprof"
@@ -113,7 +114,7 @@ func Listen(opts Options) error {
return err
}
port := listener.Addr().(*net.TCPAddr).Port
- portfile = fmt.Sprintf("%s/%d", gopsdir, os.Getpid())
+ portfile = filepath.Join(gopsdir, strconv.Itoa(os.Getpid()))
err = ioutil.WriteFile(portfile, []byte(strconv.Itoa(port)), os.ModePerm)
if err != nil {
return err