Files
LearnGO/go/pkg/mod/github.com/go-delve/liner@v1.2.3-0.20231231155935-4726ab1d7f62/signal_unix.go
T
2024-09-19 21:38:24 -04:00

17 lines
228 B
Go

// +build linux darwin openbsd freebsd netbsd
package liner
import (
"os"
"syscall"
)
func handleCtrlZ() {
pid := os.Getpid()
pgrp, err := syscall.Getpgid(pid)
if err == nil {
syscall.Kill(-pgrp, syscall.SIGTSTP)
}
}