aboutsummaryrefslogtreecommitdiffstats
path: root/include/asterisk/ast_expr.h
diff options
context:
space:
mode:
authormurf <murf@f38db490-d61c-443f-a65b-d21fe96a405b>2007-07-05 18:15:22 +0000
committermurf <murf@f38db490-d61c-443f-a65b-d21fe96a405b>2007-07-05 18:15:22 +0000
commitc66181df6174ec0fe12727a20d343eb908cbad0c (patch)
treee547079acc9ff3f5fd41827b21146c28d72030c8 /include/asterisk/ast_expr.h
parent3d7a0fea3e3c0b971b63d23184db06196dd1a771 (diff)
In regards to changes for 9508, expr2 system choking on floating point numbers, I'm adding this update to round out (no pun intended) and make this FP-capable version of the Expr2 stuff interoperate better with previous integer-only usage, by providing Functions syntax, with 20 builtin functions for floating pt to integer conversions, and some general floating point math routines that might commonly be used also. Along with this, I made it so if a function was not a builtin, it will try and find it in the ast_custom_function list, and if found, execute it and collect the results. Thus, you can call system functions like CDR(), CHANNEL(), etc, from within $\[..\] exprs, without having to wrap them in $\{...\} (curly brace) notation. Did a valgrind on the standalone and made sure there's no mem leaks. Looks good. Updated the docs, too.
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@73449 f38db490-d61c-443f-a65b-d21fe96a405b
Diffstat (limited to 'include/asterisk/ast_expr.h')
-rw-r--r--include/asterisk/ast_expr.h6
1 files changed, 4 insertions, 2 deletions
diff --git a/include/asterisk/ast_expr.h b/include/asterisk/ast_expr.h
index bc0331309..6ca201f42 100644
--- a/include/asterisk/ast_expr.h
+++ b/include/asterisk/ast_expr.h
@@ -18,12 +18,14 @@
#ifndef _ASTERISK_EXPR_H
#define _ASTERISK_EXPR_H
-
+#ifndef STANDALONE
+#include "asterisk/channel.h"
+#endif
#if defined(__cplusplus) || defined(c_plusplus)
extern "C" {
#endif
-int ast_expr(char *expr, char *buf, int length);
+int ast_expr(char *expr, char *buf, int length, struct ast_channel *chan);
#if defined(__cplusplus) || defined(c_plusplus)
}