diff options
author | Vsevolod Stakhov <vsevolod@highsecure.ru> | 2015-05-25 17:51:57 +0100 |
---|---|---|
committer | Vsevolod Stakhov <vsevolod@highsecure.ru> | 2015-05-25 17:51:57 +0100 |
commit | c43c10158c7b711b30cce1f7f8d4e0485acb3dce (patch) | |
tree | d4e82eeadcf5bdd7091c70fd98519c04df846592 | |
parent | 9f93e6ec5574057c9a9820b7b4e09ab725fff349 (diff) | |
download | rspamd-c43c10158c7b711b30cce1f7f8d4e0485acb3dce.tar.gz rspamd-c43c10158c7b711b30cce1f7f8d4e0485acb3dce.zip |
Allow __len metamethod on rspamd{text}.
-rw-r--r-- | src/lua/lua_task.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/src/lua/lua_task.c b/src/lua/lua_task.c index fccbaca7b..8a8f6c640 100644 --- a/src/lua/lua_task.c +++ b/src/lua/lua_task.c @@ -552,6 +552,7 @@ static const struct luaL_reg textlib_m[] = { LUA_INTERFACE_DEF (text, len), LUA_INTERFACE_DEF (text, str), LUA_INTERFACE_DEF (text, ptr), + {"__len", lua_text_len}, {"__tostring", lua_text_str}, {"__gc", lua_text_gc}, {NULL, NULL} |