Skip to content
This repository has been archived by the owner on Feb 17, 2021. It is now read-only.

Commit

Permalink
use different socket path based on program name
Browse files Browse the repository at this point in the history
  • Loading branch information
stamblerre committed Sep 23, 2018
1 parent 73d4bb6 commit b960ec2
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion gocode.go
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,8 @@ func getSocketPath() string {
if user == "" {
user = "all"
}
return filepath.Join(os.TempDir(), fmt.Sprintf("gocode-daemon.%s", user))
program := filepath.Base(os.Args[0])
return filepath.Join(os.TempDir(), fmt.Sprintf("%s-daemon.%s", program, user))
}

func usage() {
Expand Down

0 comments on commit b960ec2

Please sign in to comment.