diff options
author | Vsevolod Stakhov <vsevolod@highsecure.ru> | 2013-11-05 22:38:03 +0000 |
---|---|---|
committer | Vsevolod Stakhov <vsevolod@highsecure.ru> | 2013-11-05 22:38:03 +0000 |
commit | 8dc300fc2cc5a0df82d59bf4f6b3e7b0e2e79bdf (patch) | |
tree | 87dfaf6e0c71640c0cbf36bf68a815b731819115 /src/lua/lua_common.h | |
parent | e57950d1f51e5ee77e185adb459f8d66f05ce82d (diff) | |
download | rspamd-8dc300fc2cc5a0df82d59bf4f6b3e7b0e2e79bdf.tar.gz rspamd-8dc300fc2cc5a0df82d59bf4f6b3e7b0e2e79bdf.zip |
Fix work with lua 5.2 eventually.
Diffstat (limited to 'src/lua/lua_common.h')
-rw-r--r-- | src/lua/lua_common.h | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/src/lua/lua_common.h b/src/lua/lua_common.h index e2e2f032a..fd4058c11 100644 --- a/src/lua/lua_common.h +++ b/src/lua/lua_common.h @@ -23,7 +23,9 @@ static inline void luaL_register (lua_State *L, const gchar *name, const struct luaL_reg *methods) { - lua_newtable (L); + if (name != NULL) { + lua_newtable (L); + } luaL_setfuncs (L, methods, 0); if (name != NULL) { lua_pushvalue (L, -1); |