From: Vsevolod Stakhov Date: Mon, 20 Apr 2015 14:14:47 +0000 (+0100) Subject: Fix AST processing for sole comparision rules. X-Git-Tag: 0.9.0~198 X-Git-Url: https://source.dussan.org/?a=commitdiff_plain;h=52153908f55b0469a6961eb19eb8bdd86814a06b;p=rspamd.git Fix AST processing for sole comparision rules. --- diff --git a/src/libutil/expression.c b/src/libutil/expression.c index d8ed54bcd..838a4ffff 100644 --- a/src/libutil/expression.c +++ b/src/libutil/expression.c @@ -899,6 +899,11 @@ rspamd_ast_process_node (struct rspamd_expression *expr, gint flags, GNode *node celt = cld->data; /* Save limit if we've found it */ + if (celt->type == ELT_LIMIT) { + lim = celt->p.lim.val; + continue; + } + val = rspamd_ast_process_node (expr, flags, cld, data); if (acc == G_MININT) { @@ -1006,7 +1011,7 @@ rspamd_ast_string_traverse (GNode *n, gpointer d) op_str = "<="; break; case OP_LT: - op_str = ">="; + op_str = "<"; break; default: op_str = "???";