From: Vsevolod Stakhov Date: Tue, 8 Feb 2011 18:36:55 +0000 (+0300) Subject: Handle params correctly. X-Git-Tag: 0.3.7~51 X-Git-Url: https://source.dussan.org/?a=commitdiff_plain;h=849a4e522197e7bbfcb0c29ca62026e10a2a6361;p=rspamd.git Handle params correctly. --- diff --git a/src/lua/lua_common.c b/src/lua/lua_common.c index bc3748f4c..961a31d76 100644 --- a/src/lua/lua_common.c +++ b/src/lua/lua_common.c @@ -363,7 +363,7 @@ lua_call_expression_func (const gchar *module, const gchar *function, struct worker_task **ptask; GList *cur; struct expression_argument *arg; - int nargs = 0; + int nargs = 1; /* Call specified function and expect result of given expected_type */ /* First check function in config table */ @@ -416,7 +416,7 @@ lua_call_expression_func (const gchar *module, const gchar *function, } if (lua_pcall (L, nargs, 1, 0) != 0) { - msg_info ("call to %s failed", function); + msg_info ("call to %s failed: %s", function, lua_tostring (L, -1)); return FALSE; }