Login
[x]
Log in using an account from:
Fedora Account System
Red Hat Associate
Red Hat Customer
Or login using a Red Hat Bugzilla account
Forgot Password
Login:
Hide Forgot
Create an Account
Red Hat Bugzilla – Attachment 584922 Details for
Bug 820996
rsyslog writes debug messages to fd 1 even after forking
[?]
New
Simple Search
Advanced Search
My Links
Browse
Requests
Reports
Current State
Search
Tabular reports
Graphical reports
Duplicates
Other Reports
User Changes
Plotly Reports
Bug Status
Bug Severity
Non-Defaults
|
Product Dashboard
Help
Page Help!
Bug Writing Guidelines
What's new
Browser Support Policy
5.0.4.rh83 Release notes
FAQ
Guides index
User guide
Web Services
Contact
Legal
This site requires JavaScript to be enabled to function correctly, please enable it.
[patch]
proposed patch
0001-don-t-write-debug-messages-to-stdout-after-forking.patch (text/plain), 2.06 KB, created by
Tomas Heinrich
on 2012-05-16 10:15:46 UTC
(
hide
)
Description:
proposed patch
Filename:
MIME Type:
Creator:
Tomas Heinrich
Created:
2012-05-16 10:15:46 UTC
Size:
2.06 KB
patch
obsolete
>From d32cc65683627dd35ec9025d1326c0fd615f8dd6 Mon Sep 17 00:00:00 2001 >From: Tomas Heinrich <theinric@redhat.com> >Date: Tue, 15 May 2012 19:33:14 +0200 >Subject: [PATCH] don't write debug messages to stdout after forking > >--- > runtime/debug.c | 4 +--- > runtime/debug.h | 1 + > tools/syslogd.c | 3 +++ > 3 files changed, 5 insertions(+), 3 deletions(-) > >diff --git a/runtime/debug.c b/runtime/debug.c >index d02bd51..fa33b99 100644 >--- a/runtime/debug.c >+++ b/runtime/debug.c >@@ -68,7 +68,7 @@ static int bPrintAllDebugOnExit = 0; > static int bAbortTrace = 1; /* print a trace after SIGABRT or SIGSEGV */ > static char *pszAltDbgFileName = NULL; /* if set, debug output is *also* sent to here */ > static int altdbg = -1; /* and the handle for alternate debug output */ >-static int stddbg; >+int stddbg = 1; /* the handle for regular debug output, set to stdout if not forking, -1 otherwise */ > > /* list of files/objects that should be printed */ > typedef struct dbgPrintName_s { >@@ -1297,8 +1297,6 @@ dbgGetRuntimeOptions(void) > uchar *optname; > > /* set some defaults */ >- stddbg = 1; >- > if((pszOpts = (uchar*) getenv("RSYSLOG_DEBUG")) != NULL) { > /* we have options set, so let's process them */ > while(dbgGetRTOptNamVal(&pszOpts, &optname, &optval)) { >diff --git a/runtime/debug.h b/runtime/debug.h >index 717c0fe..26672c3 100644 >--- a/runtime/debug.h >+++ b/runtime/debug.h >@@ -35,6 +35,7 @@ > /* external static data elements (some time to be replaced) */ > extern int Debug; /* debug flag - read-only after startup */ > extern int debugging_on; /* read-only, except on sig USR1 */ >+extern int stddbg; /* the handle for regular debug output, set to stdout if not forking, -1 otherwise */ > > /* data types */ > >diff --git a/tools/syslogd.c b/tools/syslogd.c >index 98f0662..f3f2759 100644 >--- a/tools/syslogd.c >+++ b/tools/syslogd.c >@@ -2514,6 +2514,9 @@ doGlblProcessInit(void) > sigAct.sa_handler = doexit; > sigaction(SIGTERM, &sigAct, NULL); > >+ /* stop writing debug messages to stdout (if debugging is on) */ >+ stddbg = -1; >+ > if (fork()) { > /* Parent process > */ >-- >1.7.4.4 >
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
Attachments on
bug 820996
: 584922