summaryrefslogtreecommitdiffstats
path: root/grammar/rainerscript.c
diff options
context:
space:
mode:
authorRainer Gerhards <rgerhards@adiscon.com>2013-06-26 11:16:32 +0200
committerRainer Gerhards <rgerhards@adiscon.com>2013-06-26 11:16:32 +0200
commit696c084e51ce49dc4a3f70642df469712eed8de6 (patch)
tree5272e38099c6eb5fada9bab61487950fe32520ac /grammar/rainerscript.c
parent752e1c4b863346fe6eb8b6bc66d1d3bc3d346d13 (diff)
downloadrsyslog-696c084e51ce49dc4a3f70642df469712eed8de6.tar.gz
rsyslog-696c084e51ce49dc4a3f70642df469712eed8de6.tar.bz2
rsyslog-696c084e51ce49dc4a3f70642df469712eed8de6.zip
bugfix: call to ruleset with async queue did not use the queue
closes: http://bugzilla.adiscon.com/show_bug.cgi?id=443
Diffstat (limited to 'grammar/rainerscript.c')
-rw-r--r--grammar/rainerscript.c13
1 files changed, 10 insertions, 3 deletions
diff --git a/grammar/rainerscript.c b/grammar/rainerscript.c
index 95972fbe..a7828839 100644
--- a/grammar/rainerscript.c
+++ b/grammar/rainerscript.c
@@ -2274,7 +2274,8 @@ cnfstmtPrintOnly(struct cnfstmt *stmt, int indent, sbool subtree)
break;
case S_CALL:
cstr = es_str2cstr(stmt->d.s_call.name, NULL);
- doIndent(indent); dbgprintf("CALL [%s]\n", cstr);
+ doIndent(indent); dbgprintf("CALL [%s, queue:%d]\n", cstr,
+ stmt->d.s_call.ruleset == NULL ? 0 : 1);
free(cstr);
break;
case S_ACT:
@@ -3089,8 +3090,14 @@ cnfstmtOptimizeCall(struct cnfstmt *stmt)
stmt->nodetype = S_NOP;
goto done;
}
- DBGPRINTF("CALL obtained ruleset ptr %p for ruleset %s\n", pRuleset, rsName);
- stmt->d.s_call.stmt = pRuleset->root;
+ DBGPRINTF("CALL obtained ruleset ptr %p for ruleset %s [hasQueue:%d]\n",
+ pRuleset, rsName, rulesetHasQueue(pRuleset));
+ if(rulesetHasQueue(pRuleset)) {
+ stmt->d.s_call.ruleset = pRuleset;
+ } else {
+ stmt->d.s_call.ruleset = NULL;
+ stmt->d.s_call.stmt = pRuleset->root;
+ }
done:
free(rsName);
return;