go-serviceman/runner/runner_notwindows.go

21 lines
231 B
Go
Raw Normal View History

2019-07-03 09:04:28 +00:00
// +build !windows
package runner
import (
"os"
"os/exec"
)
2019-07-03 09:04:28 +00:00
func backgroundCmd(cmd *exec.Cmd) {
}
func kill(pid int) error {
p, err := os.FindProcess(pid)
// already died
if nil != err {
return nil
}
return p.Kill()
}