summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRainer Gerhards <rgerhards@adiscon.com>2013-03-20 12:49:35 +0100
committerRainer Gerhards <rgerhards@adiscon.com>2013-03-20 12:49:35 +0100
commitcbe737ed06667b5bcb15f332061ebcde8d50bc8b (patch)
treeb8e3f79e4dab90fc804814f9ed5df031dd8c31ba
parent2b69e2aaddb587185b7c0ddb412b36549d848091 (diff)
downloadrsyslog-cbe737ed06667b5bcb15f332061ebcde8d50bc8b.tar.gz
rsyslog-cbe737ed06667b5bcb15f332061ebcde8d50bc8b.tar.bz2
rsyslog-cbe737ed06667b5bcb15f332061ebcde8d50bc8b.zip
bugfix: stdout/stderr were not closed on forking
but were closed when running in the forground - this was just reversed of what it should be. This is a regression of a recent change.
-rw-r--r--ChangeLog3
-rw-r--r--tools/syslogd.c2
2 files changed, 4 insertions, 1 deletions
diff --git a/ChangeLog b/ChangeLog
index 705dcf13..c6a4eb41 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,6 +1,9 @@
---------------------------------------------------------------------------
Version 7.3.9 [devel] 2013-03-??
- bugfix: build problems on non-Linux platforms
+- bugfix: stdout/stderr were not closed on forking
+ but were closed when running in the forground - this was just reversed
+ of what it should be. This is a regression of a recent change.
---------------------------------------------------------------------------
Version 7.3.8 [devel] 2013-03-18
- imrelp: now supports listening to IPv4/v6 only instead of always both
diff --git a/tools/syslogd.c b/tools/syslogd.c
index d4fc1c36..e291ba47 100644
--- a/tools/syslogd.c
+++ b/tools/syslogd.c
@@ -2021,7 +2021,7 @@ int realMain(int argc, char **argv)
* is still in its infancy (and not really done), we currently accept this issue.
* rgerhards, 2009-06-29
*/
- if(!doFork) {
+ if(doFork) {
close(1);
close(2);
ourConf->globals.bErrMsgToStderr = 0;