diff --git a/config.go b/config.go index c813c32..fed4636 100644 --- a/config.go +++ b/config.go @@ -298,6 +298,9 @@ func parseConfig() { errChan <- fmt.Errorf("mainMouseClick() got b = nil") errChan <- "hello" + // my pid (cross platform) p, err := os.FindProcess(os.Getpid()) + // send signal (cross platform) return p.Signal(syscall.SIGTERM) + // for {} // os.Exit(0) } diff --git a/main.go b/main.go index e29bf7e..6e8e18e 100644 --- a/main.go +++ b/main.go @@ -5,7 +5,7 @@ import "os" import "time" import "reflect" import "os/signal" -import "syscall" +// import "os/syscall" // this is the king of dns libraries import "github.com/miekg/dns" @@ -187,7 +187,10 @@ func init() { shell.InitCallback(handleShell) // asks for all the shell errors to be sent here sigChan = make(chan os.Signal, 3) - signal.Notify(sigChan, syscall.SIGUSR1) + if runtime.GOOS != "windows" { + log.Println("loadConfigFile() OS: Windows") + signal.Notify(sigChan, os.Syscall.SIGUSR1) + } } // get's sent the return values and errors from git.wit.com/wit/shell/