summaryrefslogtreecommitdiffstats
path: root/runtime/expr.c
diff options
context:
space:
mode:
authorRainer Gerhards <rgerhards@adiscon.com>2009-04-06 17:55:04 +0200
committerRainer Gerhards <rgerhards@adiscon.com>2009-04-06 17:55:04 +0200
commit8e3c5a9ca3732a41fbb8581b13c49acd699820da (patch)
treef75be0a65a7ab52fd3c35d240d0cc0446d3e883d /runtime/expr.c
parent010060289a729dd930ac04b72237f0ca0db9ea1d (diff)
downloadrsyslog-8e3c5a9ca3732a41fbb8581b13c49acd699820da.tar.gz
rsyslog-8e3c5a9ca3732a41fbb8581b13c49acd699820da.tar.xz
rsyslog-8e3c5a9ca3732a41fbb8581b13c49acd699820da.zip
improved internal handling of RainerScript functions
- building the necessary plumbing to support more functions with decent runtime performance. This is also necessary towards the long-term goal of loadable library modules. - added new RainerScript function "tolower"
Diffstat (limited to 'runtime/expr.c')
-rw-r--r--runtime/expr.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/runtime/expr.c b/runtime/expr.c
index 38ed1c68..e449d1c7 100644
--- a/runtime/expr.c
+++ b/runtime/expr.c
@@ -142,7 +142,9 @@ terminal(expr_t *pThis, ctok_t *tok)
* we have all relevant information)
*/
CHKiRet(ctok_token.UnlinkVar(pToken, &pVar));
- CHKiRet(vmprg.AddVarOperation(pThis->pVmprg, opcode_FUNC_CALL, pVar)); /* add to program */
+ CHKiRet(var.ConvToString(pVar)); /* make sure we have a string */
+ CHKiRet(vmprg.AddCallOperation(pThis->pVmprg, pVar->val.pStr)); /* add to program */
+ CHKiRet(var.Destruct(&pVar));
break;
case ctok_MSGVAR:
dbgoprint((obj_t*) pThis, "MSGVAR\n");