summaryrefslogtreecommitdiffstats
path: root/src/lua/lua_classifier.c
diff options
context:
space:
mode:
authorVsevolod Stakhov <vsevolod@highsecure.ru>2015-01-23 15:36:31 +0000
committerVsevolod Stakhov <vsevolod@highsecure.ru>2015-01-23 15:36:31 +0000
commit8ebc43f86166fd121d9634349dfca873cb92278c (patch)
tree33a8c5843dbd3426fb16c0fd591d3f5343c764df /src/lua/lua_classifier.c
parent8a05515078bc8fd3d642778fcae0d005a38ec7b0 (diff)
downloadrspamd-8ebc43f86166fd121d9634349dfca873cb92278c.tar.gz
rspamd-8ebc43f86166fd121d9634349dfca873cb92278c.zip
Rework classifiers configuration and naming.
Now it is possible to register multiple classifiers with the same type.
Diffstat (limited to 'src/lua/lua_classifier.c')
-rw-r--r--src/lua/lua_classifier.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/src/lua/lua_classifier.c b/src/lua/lua_classifier.c
index 7adc473ba..c338fb294 100644
--- a/src/lua/lua_classifier.c
+++ b/src/lua/lua_classifier.c
@@ -25,7 +25,6 @@
#include "lua_common.h"
#include "cfg_file.h"
-#include "classifiers.h"
/* Classifier methods */
LUA_FUNCTION_DEF (classifier, register_pre_callback);
@@ -147,7 +146,7 @@ rspamd_lua_call_cls_pre_callbacks (struct rspamd_classifier_config *ccf,
/* Check function from global table 'classifiers' */
lua_getglobal (L, "classifiers");
if (lua_istable (L, -1)) {
- lua_pushstring (L, ccf->classifier->name);
+ lua_pushstring (L, ccf->name);
lua_gettable (L, -2);
/* Function is now on top */
if (lua_isfunction (L, -1)) {