aboutsummaryrefslogtreecommitdiffstats
path: root/src/libutil/expression.h
diff options
context:
space:
mode:
authorVsevolod Stakhov <vsevolod@highsecure.ru>2017-09-30 11:32:54 +0100
committerVsevolod Stakhov <vsevolod@highsecure.ru>2017-09-30 11:32:54 +0100
commitb0bc4a9e9c89e4976e7a14f18d0595ec2b6e8213 (patch)
tree51b139d12ff2fcc59c00d32a5fcd46952a4b841b /src/libutil/expression.h
parent9f8bcbd508f081c79d75bc32b81cfb8ac09c4b1c (diff)
downloadrspamd-b0bc4a9e9c89e4976e7a14f18d0595ec2b6e8213.tar.gz
rspamd-b0bc4a9e9c89e4976e7a14f18d0595ec2b6e8213.zip
[Rework] Use floating point arithmetics in Rspamd expressions
Diffstat (limited to 'src/libutil/expression.h')
-rw-r--r--src/libutil/expression.h6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/libutil/expression.h b/src/libutil/expression.h
index 2c0ec7497..fefde2974 100644
--- a/src/libutil/expression.h
+++ b/src/libutil/expression.h
@@ -61,7 +61,7 @@ struct rspamd_atom_subr {
rspamd_expression_atom_t * (*parse)(const gchar *line, gsize len,
rspamd_mempool_t *pool, gpointer ud, GError **err);
/* Process atom via the opaque pointer (e.g. struct rspamd_task *) */
- gint (*process) (gpointer input, rspamd_expression_atom_t *atom);
+ gdouble (*process) (gpointer input, rspamd_expression_atom_t *atom);
/* Calculates the relative priority of the expression */
gint (*priority) (rspamd_expression_atom_t *atom);
void (*destroy) (rspamd_expression_atom_t *atom);
@@ -92,7 +92,7 @@ gboolean rspamd_parse_expression (const gchar *line, gsize len,
* @param data opaque data pointer for all the atoms
* @return the value of expression
*/
-gint rspamd_process_expression (struct rspamd_expression *expr, gint flags,
+gdouble rspamd_process_expression (struct rspamd_expression *expr, gint flags,
gpointer data);
/**
@@ -103,7 +103,7 @@ gint rspamd_process_expression (struct rspamd_expression *expr, gint flags,
* @param track pointer array to atoms tracking
* @return the value of expression
*/
-gint rspamd_process_expression_track (struct rspamd_expression *expr, gint flags,
+gdouble rspamd_process_expression_track (struct rspamd_expression *expr, gint flags,
gpointer data, GPtrArray *track);
/**