diff options
Diffstat (limited to 'src/mime.c')
-rw-r--r-- | src/mime.c | 8 |
1 files changed, 2 insertions, 6 deletions
@@ -81,13 +81,9 @@ static UC b64unbase[256]; | |||
81 | \*-------------------------------------------------------------------------*/ | 81 | \*-------------------------------------------------------------------------*/ |
82 | MIME_API int luaopen_mime_core(lua_State *L) | 82 | MIME_API int luaopen_mime_core(lua_State *L) |
83 | { | 83 | { |
84 | #if LUA_VERSION_NUM > 501 | 84 | #if LUA_VERSION_NUM > 501 && !defined(LUA_COMPAT_MODULE) |
85 | lua_newtable(L); | 85 | lua_newtable(L); |
86 | #ifdef LUASOCKET_USE_GLOBAL | 86 | luaL_setfuncs(L, func, 0); |
87 | lua_setglobal(L,"mime"); | ||
88 | lua_getglobal(L,"mime"); | ||
89 | #endif | ||
90 | luaL_setfuncs(L,func,0); | ||
91 | #else | 87 | #else |
92 | luaL_openlib(L, "mime", func, 0); | 88 | luaL_openlib(L, "mime", func, 0); |
93 | #endif | 89 | #endif |