aboutsummaryrefslogtreecommitdiff
path: root/src/unix.c
diff options
context:
space:
mode:
authorDiego Nehab <diego@tecgraf.puc-rio.br>2004-07-01 05:35:35 +0000
committerDiego Nehab <diego@tecgraf.puc-rio.br>2004-07-01 05:35:35 +0000
commit197aef23ce36844e86e732f26af1df9fc5f149da (patch)
treefdc7e11c0fd653c3c25360f532d0648b0e822ad9 /src/unix.c
parenta7d5362caffb928e2947b9ef99d1165391a510da (diff)
downloadluasocket-197aef23ce36844e86e732f26af1df9fc5f149da.tar.gz
luasocket-197aef23ce36844e86e732f26af1df9fc5f149da.tar.bz2
luasocket-197aef23ce36844e86e732f26af1df9fc5f149da.zip
Compiles with g++.
Diffstat (limited to '')
-rw-r--r--src/unix.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/unix.c b/src/unix.c
index 34d2da1..407f85d 100644
--- a/src/unix.c
+++ b/src/unix.c
@@ -111,7 +111,7 @@ static int meth_receive(lua_State *L) {
111* Just call option handler 111* Just call option handler
112\*-------------------------------------------------------------------------*/ 112\*-------------------------------------------------------------------------*/
113static int meth_setoption(lua_State *L) { 113static int meth_setoption(lua_State *L) {
114 p_unix unix = aux_checkgroup(L, "unix{any}", 1); 114 p_unix unix = (p_unix) aux_checkgroup(L, "unix{any}", 1);
115 return opt_meth_setoption(L, opt, &unix->sock); 115 return opt_meth_setoption(L, opt, &unix->sock);
116} 116}
117 117
@@ -148,7 +148,7 @@ static int meth_accept(lua_State *L) {
148 const char *err = sock_accept(&server->sock, &sock, NULL, NULL, tm); 148 const char *err = sock_accept(&server->sock, &sock, NULL, NULL, tm);
149 /* if successful, push client socket */ 149 /* if successful, push client socket */
150 if (!err) { 150 if (!err) {
151 p_unix clnt = lua_newuserdata(L, sizeof(t_unix)); 151 p_unix clnt = (p_unix) lua_newuserdata(L, sizeof(t_unix));
152 aux_setclass(L, "unix{client}", -1); 152 aux_setclass(L, "unix{client}", -1);
153 /* initialize structure fields */ 153 /* initialize structure fields */
154 sock_setnonblocking(&sock); 154 sock_setnonblocking(&sock);