diff options
author | Vsevolod Stakhov <vsevolod@highsecure.ru> | 2013-11-15 14:55:40 +0000 |
---|---|---|
committer | Vsevolod Stakhov <vsevolod@highsecure.ru> | 2013-11-15 14:55:40 +0000 |
commit | 418b59eb3b01a3729146e3d48c96a5687baed2c9 (patch) | |
tree | 403ce8a01e5be9befc25e2b5491478d631569004 /src/lua/lua_classifier.c | |
parent | c2433f1728704e794e729ac1e3518596218d368e (diff) | |
download | rspamd-418b59eb3b01a3729146e3d48c96a5687baed2c9.tar.gz rspamd-418b59eb3b01a3729146e3d48c96a5687baed2c9.zip |
Fix options in statfiles.
Diffstat (limited to 'src/lua/lua_classifier.c')
-rw-r--r-- | src/lua/lua_classifier.c | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/src/lua/lua_classifier.c b/src/lua/lua_classifier.c index 33e7ea9f2..be574319a 100644 --- a/src/lua/lua_classifier.c +++ b/src/lua/lua_classifier.c @@ -381,14 +381,15 @@ static gint lua_statfile_get_param (lua_State *L) { struct statfile *st = lua_check_statfile (L); - const gchar *param, *value; + const gchar *param; + ucl_object_t *value; param = luaL_checkstring (L, 2); if (st != NULL && param != NULL) { - value = g_hash_table_lookup (st->opts, param); + value = ucl_object_find_key (st->opts, param); if (value != NULL) { - lua_pushstring (L, value); + lua_pushstring (L, ucl_object_tostring_forced (value)); return 1; } } |