aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorHelge Deller <deller@gmx.de>2020-09-28 15:28:18 +0200
committerHelge Deller <deller@gmx.de>2020-09-28 15:28:18 +0200
commit38026433afc21752774f559825c98301e6f7f65c (patch)
tree8f207c7f25f4b105f1a8cb2545b0d30fb5c4f451
parent731247af990d9c80a187822a6b89351025516e07 (diff)
downloadrbootd-38026433afc21752774f559825c98301e6f7f65c.tar.gz
rboot.c: Exit with code 0 if terminating via SIGTERM
systemd sends a SIGTERM, in which case rbootd should exit with return code 0 to avoid a warning by systemd that the stop failed. Signed-off-by: Helge Deller <deller@gmx.de>
-rw-r--r--rbootd.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/rbootd.c b/rbootd.c
index 053e320..ec78c18 100644
--- a/rbootd.c
+++ b/rbootd.c
@@ -491,7 +491,7 @@ Exit(sig)
#else
BpfClose();
#endif
- exit(1);
+ exit(sig > 0 ? 0:1);
}
/*