aboutsummaryrefslogtreecommitdiff
path: root/src/auxiliar.c
diff options
context:
space:
mode:
authorDiego Nehab <diego@tecgraf.puc-rio.br>2004-01-19 18:22:51 +0000
committerDiego Nehab <diego@tecgraf.puc-rio.br>2004-01-19 18:22:51 +0000
commit3f1712ed48f9deab4fab67d7d342dc20c2b5b0ce (patch)
tree4843296b98ab3524b9cbed1c6428b101e8107492 /src/auxiliar.c
parentfbb42b80cb0d299f38e0a4df9b0fa01228b39225 (diff)
downloadluasocket-3f1712ed48f9deab4fab67d7d342dc20c2b5b0ce.tar.gz
luasocket-3f1712ed48f9deab4fab67d7d342dc20c2b5b0ce.tar.bz2
luasocket-3f1712ed48f9deab4fab67d7d342dc20c2b5b0ce.zip
Added gethostname.
Cleaned up TODO. Moved luasocket specific stuff from auxiliar.c to luasocket.c
Diffstat (limited to 'src/auxiliar.c')
-rw-r--r--src/auxiliar.c19
1 files changed, 1 insertions, 18 deletions
diff --git a/src/auxiliar.c b/src/auxiliar.c
index 65425c5..4b3a0f6 100644
--- a/src/auxiliar.c
+++ b/src/auxiliar.c
@@ -17,24 +17,7 @@
17\*-------------------------------------------------------------------------*/ 17\*-------------------------------------------------------------------------*/
18void aux_open(lua_State *L) 18void aux_open(lua_State *L)
19{ 19{
20 /* create namespace table */ 20 ;
21 lua_pushstring(L, LUASOCKET_LIBNAME);
22 lua_newtable(L);
23#ifdef LUASOCKET_DEBUG
24 lua_pushstring(L, "debug");
25 lua_pushnumber(L, 1);
26 lua_rawset(L, -3);
27#endif
28 /* make version string available so scripts */
29 lua_pushstring(L, "version");
30 lua_pushstring(L, LUASOCKET_VERSION);
31 lua_rawset(L, -3);
32 /* store namespace as global */
33 lua_settable(L, LUA_GLOBALSINDEX);
34 /* make sure modules know what is our namespace */
35 lua_pushstring(L, "LUASOCKET_LIBNAME");
36 lua_pushstring(L, LUASOCKET_LIBNAME);
37 lua_settable(L, LUA_GLOBALSINDEX);
38} 21}
39 22
40/*-------------------------------------------------------------------------*\ 23/*-------------------------------------------------------------------------*\