Global code ovehaul - remove CAS and other, add 15 minute greet check
- Remove CAS, as it no longer works for us - Remove other checks - Implement 15 minute greet timeout check - Fix chat logos - Ditch thirdparty logger, use stdlib log facility wrapper for logging
This commit is contained in:
28
internal/moon/exitCode_unix.go
Normal file
28
internal/moon/exitCode_unix.go
Normal file
@@ -0,0 +1,28 @@
|
||||
//go:build !windows
|
||||
|
||||
package moon
|
||||
|
||||
import (
|
||||
"os"
|
||||
"syscall"
|
||||
)
|
||||
|
||||
// exitCodeFor maps one terminating signal to the status a stopped process
|
||||
// should carry: 128 + the signal's number on Unix.
|
||||
func exitCodeFor(s os.Signal) int {
|
||||
switch s {
|
||||
case syscall.SIGINT:
|
||||
return signalExitBase + 2
|
||||
|
||||
case syscall.SIGTERM:
|
||||
return signalExitBase + 15
|
||||
|
||||
case syscall.SIGQUIT:
|
||||
return signalExitBase + 3
|
||||
|
||||
default:
|
||||
return 0
|
||||
}
|
||||
}
|
||||
|
||||
/* vim: set ft=go noet ai ts=4 sw=4 sts=4: */
|
||||
Reference in New Issue
Block a user