File: 51_exit-with-status-0-when-stopping-with-SIGTERM.patch

package info (click to toggle)
arpwatch 2.1a15-8
  • links: PTS, VCS
  • area: main
  • in suites: bookworm, bullseye
  • size: 1,988 kB
  • sloc: sh: 3,047; ansic: 2,811; makefile: 90; awk: 90; perl: 15
file content (19 lines) | stat: -rw-r--r-- 524 bytes parent folder | download | duplicates (3)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
Origin: http://pkgs.fedoraproject.org/cgit/rpms/arpwatch.git/plain/arpwatch-exitcode.patch
Description: exit with status 0 when stopping with SIGTERM
 With this patch systemd can distinguish an unclean shutdown from a clean one.
 This is useful for implementing an automatic restart in case arpwatch crashes.
---
 arpwatch.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

--- a/arpwatch.c
+++ b/arpwatch.c
@@ -887,7 +887,7 @@
 
 	syslog(LOG_DEBUG, "exiting");
 	checkpoint(0);
-	exit(1);
+	exit(0);
 }
 
 RETSIGTYPE