aboutsummaryrefslogtreecommitdiff
path: root/src/luasocket.c
diff options
context:
space:
mode:
authorDiego Nehab <diego@tecgraf.puc-rio.br>2005-02-08 10:01:01 +0000
committerDiego Nehab <diego@tecgraf.puc-rio.br>2005-02-08 10:01:01 +0000
commit8d4e240f6ae50d9b22ddc44f5e207018935da907 (patch)
treed8ca9a51dc35534592f700e42740feac20242ede /src/luasocket.c
parent5d32848674b723521e87836eafa24f5ae8f80a89 (diff)
downloadluasocket-8d4e240f6ae50d9b22ddc44f5e207018935da907.tar.gz
luasocket-8d4e240f6ae50d9b22ddc44f5e207018935da907.tar.bz2
luasocket-8d4e240f6ae50d9b22ddc44f5e207018935da907.zip
Forward server working on Mac OS X...
Diffstat (limited to 'src/luasocket.c')
-rw-r--r--src/luasocket.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/luasocket.c b/src/luasocket.c
index 4b829f8..8f13dbc 100644
--- a/src/luasocket.c
+++ b/src/luasocket.c
@@ -87,7 +87,7 @@ static int global_unload(lua_State *L) {
87static int base_open(lua_State *L) { 87static int base_open(lua_State *L) {
88 if (sock_open()) { 88 if (sock_open()) {
89 /* export functions (and leave namespace table on top of stack) */ 89 /* export functions (and leave namespace table on top of stack) */
90 luaL_module(L, "socket", func, 0); 90 luaL_openlib(L, "socket", func, 0);
91#ifdef LUASOCKET_DEBUG 91#ifdef LUASOCKET_DEBUG
92 lua_pushstring(L, "DEBUG"); 92 lua_pushstring(L, "DEBUG");
93 lua_pushboolean(L, 1); 93 lua_pushboolean(L, 1);
@@ -108,7 +108,7 @@ static int base_open(lua_State *L) {
108/*-------------------------------------------------------------------------*\ 108/*-------------------------------------------------------------------------*\
109* Initializes all library modules. 109* Initializes all library modules.
110\*-------------------------------------------------------------------------*/ 110\*-------------------------------------------------------------------------*/
111LUASOCKET_API int luaopen_lsocket(lua_State *L) { 111LUASOCKET_API int luaopen_csocket(lua_State *L) {
112 int i; 112 int i;
113 base_open(L); 113 base_open(L);
114 for (i = 0; mod[i].name; i++) mod[i].func(L); 114 for (i = 0; mod[i].name; i++) mod[i].func(L);