rsyslog/rsyslog-3.21.9-dodie.patch
Tomas Heinrich 5fb5ea619e - fix several legacy options handling
- fix internal message output (#478612)
2009-01-07 12:08:38 +00:00

18 lines
656 B
Diff

diff -up rsyslog-3.21.9/tools/syslogd.c.dodie rsyslog-3.21.9/tools/syslogd.c
--- rsyslog-3.21.9/tools/syslogd.c.dodie 2009-01-05 17:20:33.000000000 +0100
+++ rsyslog-3.21.9/tools/syslogd.c 2009-01-05 17:25:19.000000000 +0100
@@ -1877,9 +1877,11 @@ static void doDie(int sig)
# define MSG1 "DoDie called.\n"
# define MSG2 "DoDie called 5 times - unconditional exit\n"
static int iRetries = 0; /* debug aid */
- write(1, MSG1, sizeof(MSG1));
+ if(Debug || NoFork)
+ write(1, MSG1, sizeof(MSG1) - 1);
if(iRetries++ == 4) {
- write(1, MSG2, sizeof(MSG2));
+ if(Debug || NoFork)
+ write(1, MSG2, sizeof(MSG2) - 1);
abort();
}
bFinished = sig;