summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRainer Gerhards <rgerhards@adiscon.com>2012-02-02 16:47:19 +0100
committerRainer Gerhards <rgerhards@adiscon.com>2012-02-02 16:47:19 +0100
commit5494790ece676ca0a07c0a62cb457338ec4cec90 (patch)
tree2f5cc27bb928d688d47435dd3823a89c7bb0c2dd
parent03cf2a5113e130e4f64b048dc4dc6d2c0aa1b3b2 (diff)
downloadrsyslog-5494790ece676ca0a07c0a62cb457338ec4cec90.tar.gz
rsyslog-5494790ece676ca0a07c0a62cb457338ec4cec90.tar.xz
rsyslog-5494790ece676ca0a07c0a62cb457338ec4cec90.zip
bugfix: abort during startup when rsyslog.conf v6+ format was used in a certain way
-rw-r--r--ChangeLog4
-rw-r--r--action.c4
-rw-r--r--tests/Makefile.am3
-rwxr-xr-x[-rw-r--r--]tests/mysql-basic-cnf6.sh0
-rw-r--r--tests/testsuites/mysql-basic-cnf6.conf8
5 files changed, 13 insertions, 6 deletions
diff --git a/ChangeLog b/ChangeLog
index 9e42b1ff..2a38431b 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,4 +1,8 @@
---------------------------------------------------------------------------
+Version 6.3.8 [DEVEL] 2012-02-??
+- bugfix: abort during startup when rsyslog.conf v6+ format was used in
+ a certain way
+---------------------------------------------------------------------------
Version 6.3.7 [DEVEL] 2012-02-02
- imported refactored v5.9.6 imklog linux driver, now combined with BSD
driver
diff --git a/action.c b/action.c
index b4b03ea1..0b0f27c3 100644
--- a/action.c
+++ b/action.c
@@ -1815,10 +1815,11 @@ doSubmitToActionQComplexBatch(action_t *pAction, batch_t *pBatch)
* Defaults must have been set appropriately during action construct!
* rgerhards, 2011-08-01
*/
-rsRetVal
+static rsRetVal
actionApplyCnfParam(action_t *pAction, struct cnfparamvals *pvals)
{
int i;
+
for(i = 0 ; i < pblk.nParams ; ++i) {
if(!pvals[i].bUsed)
continue;
@@ -1847,7 +1848,6 @@ actionApplyCnfParam(action_t *pAction, struct cnfparamvals *pvals)
"param '%s'\n", pblk.descr[i].name);
}
}
- cnfparamvalsDestruct(pvals, &pblk);
return RS_RET_OK;
}
diff --git a/tests/Makefile.am b/tests/Makefile.am
index 9893afab..50ce2e0b 100644
--- a/tests/Makefile.am
+++ b/tests/Makefile.am
@@ -82,6 +82,7 @@ endif
if ENABLE_MYSQL_TESTS
TESTS += \
mysql-basic.sh \
+ mysql-basic-cnf6.sh \
mysql-asyn.sh
if ENABLE_OMLIBDBI
TESTS += \
@@ -457,8 +458,10 @@ EXTRA_DIST= 1.rstest 2.rstest 3.rstest err1.rstest \
libdbi-asyn.sh \
testsuites/libdbi-asyn.conf \
mysql-basic.sh \
+ mysql-basic-cnf6.sh \
mysql-basic-vg.sh \
testsuites/mysql-basic.conf \
+ testsuites/mysql-basic-cnf6.conf \
mysql-asyn.sh \
mysql-asyn-vg.sh \
testsuites/mysql-asyn.conf \
diff --git a/tests/mysql-basic-cnf6.sh b/tests/mysql-basic-cnf6.sh
index 8990ba35..8990ba35 100644..100755
--- a/tests/mysql-basic-cnf6.sh
+++ b/tests/mysql-basic-cnf6.sh
diff --git a/tests/testsuites/mysql-basic-cnf6.conf b/tests/testsuites/mysql-basic-cnf6.conf
index bc95dc4f..12bd0b29 100644
--- a/tests/testsuites/mysql-basic-cnf6.conf
+++ b/tests/testsuites/mysql-basic-cnf6.conf
@@ -1,7 +1,7 @@
$IncludeConfig diag-common.conf
$ModLoad ../plugins/ommysql/.libs/ommysql
-:msg, contains, "msgnum:" action(type="ommysql"
- server="127.0.0.1"
- db="Syslog
- uid="rsyslog" pwd="testbench")
+if $msg contains 'msgnum' then {
+ action(type="ommysql" server="127.0.0.1"
+ db="Syslog" uid="rsyslog" pwd="testbench")
+}