summaryrefslogtreecommitdiff
path: root/src/nshd
diff options
context:
space:
mode:
authorLuke Shumaker <lukeshu@sbcglobal.net>2015-09-03 13:45:38 -0600
committerLuke Shumaker <lukeshu@sbcglobal.net>2015-09-03 13:45:38 -0600
commit5a9bf43f0e5e7904b64c432d67d3226e2a7ddfca (patch)
tree134f8dd308305d364508034e6c389faa9d5dca21 /src/nshd
parent3ab61b3e5032805784343dcab16f94f8252a88c4 (diff)
Use systemd/lsb exit codes, consistently
Diffstat (limited to 'src/nshd')
-rw-r--r--src/nshd/hackers_git/hackers_watch.go3
-rw-r--r--src/nshd/main.go2
2 files changed, 3 insertions, 2 deletions
diff --git a/src/nshd/hackers_git/hackers_watch.go b/src/nshd/hackers_git/hackers_watch.go
index a878f4c..3d72f94 100644
--- a/src/nshd/hackers_git/hackers_watch.go
+++ b/src/nshd/hackers_git/hackers_watch.go
@@ -5,6 +5,7 @@ import (
"os"
"path/filepath"
"sd_daemon/logger"
+ "sd_daemon/lsb"
)
const (
@@ -128,7 +129,7 @@ func (o *Hackers) worker_handle_passwd(uid int32) {
func worker_error(format string, a ...interface{}) {
logger.Err(format, a)
- os.Exit(255)
+ os.Exit(int(lsb.EXIT_FAILURE))
}
func (o *Hackers) worker() {
diff --git a/src/nshd/main.go b/src/nshd/main.go
index ac49eaa..ebca1a6 100644
--- a/src/nshd/main.go
+++ b/src/nshd/main.go
@@ -14,5 +14,5 @@ func main() {
backend := hackers_git.NewHackers(config)
ret := nslcd_systemd.Main(backend)
backend.Close()
- os.Exit(ret)
+ os.Exit(int(ret))
}