0
Fork 0
mirror of https://github.com/caddyserver/caddy.git synced 2024-12-30 22:34:15 -05:00
caddy/cmd/proc_posix.go

16 lines
225 B
Go

// +build !windows
package caddycmd
import (
"fmt"
"syscall"
)
func gracefullyStopProcess(pid int) error {
err := syscall.Kill(pid, syscall.SIGINT)
if err != nil {
return fmt.Errorf("kill: %v", err)
}
return nil
}