nano-run/server/internal/flags_linux.go
Alexander Baryshnikov 4edfaa4d26 initial code added
2020-09-10 18:11:34 +08:00

15 lines
240 B
Go

package internal
import (
"os/exec"
"syscall"
)
func SetBinFlags(cmd *exec.Cmd) {
if cmd.SysProcAttr == nil {
cmd.SysProcAttr = &syscall.SysProcAttr{}
}
cmd.SysProcAttr.Pdeathsig = syscall.SIGTERM
cmd.SysProcAttr.Setpgid = true
}