summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRainer Gerhards <rgerhards@adiscon.com>2009-05-29 14:24:58 +0200
committerRainer Gerhards <rgerhards@adiscon.com>2009-05-29 14:24:58 +0200
commit53fc3b9af9d257db5ad7b0f8019569e36dc35ce4 (patch)
tree802facfa518a3c8d3dd2e8e165bc88bbd572442a
parent8e180e152ab1cd332a212648d6a0f2e2583a2bca (diff)
parent02929c7bbf1189a4fc96e42fb127f2f04a279719 (diff)
downloadrsyslog-53fc3b9af9d257db5ad7b0f8019569e36dc35ce4.tar.gz
rsyslog-53fc3b9af9d257db5ad7b0f8019569e36dc35ce4.tar.xz
rsyslog-53fc3b9af9d257db5ad7b0f8019569e36dc35ce4.zip
Merge branch 'beta'
-rw-r--r--ChangeLog5
-rw-r--r--plugins/imdiag/imdiag.c3
-rw-r--r--tools/syslogd.c35
3 files changed, 25 insertions, 18 deletions
diff --git a/ChangeLog b/ChangeLog
index dea7fee4..931f21f8 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -199,7 +199,7 @@ version before switching to this one.
- bugfix: memory leak in ompgsql
Thanks to Ken for providing the patch
---------------------------------------------------------------------------
-Version 3.22.x [v3-stable] (rgerhards), 2009-04-??
+Version 3.22.1 [v3-stable] (rgerhards), 2009-04-??
- bugfix: internal messages were emitted to whatever file had fd2 when
rsyslogd ran in forked mode (as usual!)
Thanks to varmojfekoj for the patch
@@ -209,14 +209,13 @@ Version 3.22.x [v3-stable] (rgerhards), 2009-04-??
the change requires more code than I had hoped. Thus I have NOT tried
to actually catch all cases, this is left for the current devel
releases, if necessary]
----------------------------------------------------------------------------
-Version 3.22.1 [v3-stable] (rgerhards), 2009-04-??
- bugfix: light and full delay watermarks had invalid values, badly
affecting performance for delayable inputs
- bugfix: potential segfault issue when multiple $UDPServerRun directives
are specified. Thanks to Michael Biebl for helping to debug this one.
- relaxed GnuTLS version requirement to 1.4.0 after confirmation from the
field that this version is sufficient
+- bugfix: parser did not properly handle empty structured data
---------------------------------------------------------------------------
Version 3.22.0 [v3-stable] (rgerhards), 2009-04-21
This is the first stable release that includes the full functionality
diff --git a/plugins/imdiag/imdiag.c b/plugins/imdiag/imdiag.c
index c700cab7..129241fa 100644
--- a/plugins/imdiag/imdiag.c
+++ b/plugins/imdiag/imdiag.c
@@ -1,3 +1,5 @@
+#warning "imdiag is NOT supported in this version of rsyslog"
+#if 0
/* imdiag.c
* This is a diagnostics module, primarily meant for troubleshooting
* and information about the runtime state of rsyslog. It is implemented
@@ -457,6 +459,7 @@ CODEmodInit_QueryRegCFSLineHdlr
CHKiRet(omsdRegCFSLineHdlr(UCHAR_CONSTANT("resetconfigvariables"), 1, eCmdHdlrCustomHandler,
resetConfigVariables, NULL, STD_LOADABLE_MODULE_ID));
ENDmodInit
+#endif
/* vim:set ai:
diff --git a/tools/syslogd.c b/tools/syslogd.c
index 69c24ae6..d925505f 100644
--- a/tools/syslogd.c
+++ b/tools/syslogd.c
@@ -1311,21 +1311,26 @@ static int parseRFCStructuredData(uchar **pp2parse, uchar *pResult)
if(*p2parse != '[')
return 1; /* this is NOT structured data! */
- while(bCont) {
- if(*p2parse == '\0') {
- iRet = 1; /* this is not valid! */
- bCont = 0;
- } else if(*p2parse == '\\' && *(p2parse+1) == ']') {
- /* this is escaped, need to copy both */
- *pResult++ = *p2parse++;
- *pResult++ = *p2parse++;
- } else if(*p2parse == ']' && *(p2parse+1) == ' ') {
- /* found end, just need to copy the ] and eat the SP */
- *pResult++ = *p2parse;
- p2parse += 2;
- bCont = 0;
- } else {
- *pResult++ = *p2parse++;
+ if(*p2parse == '-') { /* empty structured data? */
+ *pResult++ = '-';
+ ++p2parse;
+ } else {
+ while(bCont) {
+ if(*p2parse == '\0') {
+ iRet = 1; /* this is not valid! */
+ bCont = 0;
+ } else if(*p2parse == '\\' && *(p2parse+1) == ']') {
+ /* this is escaped, need to copy both */
+ *pResult++ = *p2parse++;
+ *pResult++ = *p2parse++;
+ } else if(*p2parse == ']' && *(p2parse+1) == ' ') {
+ /* found end, just need to copy the ] and eat the SP */
+ *pResult++ = *p2parse;
+ p2parse += 2;
+ bCont = 0;
+ } else {
+ *pResult++ = *p2parse++;
+ }
}
}