From e8ea598721ee7e7c093853cc1b8c1f5abe717f90 Mon Sep 17 00:00:00 2001 From: Apollon Oikonomopoulos Date: Thu, 17 Apr 2014 16:39:30 +0300 Subject: [PATCH] MINOR: systemd wrapper: propagate exit status Use HAProxy's exit status as the systemd wrapper's exit status instead of always returning EXIT_SUCCESS, permitting the use of systemd's `Restart = on-failure' logic. --- src/haproxy-systemd-wrapper.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/haproxy-systemd-wrapper.c b/src/haproxy-systemd-wrapper.c index d4baa90c26..ba07ebe01c 100644 --- a/src/haproxy-systemd-wrapper.c +++ b/src/haproxy-systemd-wrapper.c @@ -184,5 +184,5 @@ int main(int argc, char **argv) fprintf(stderr, SD_NOTICE "haproxy-systemd-wrapper: exit, haproxy RC=%d\n", status); - return EXIT_SUCCESS; + return status; }