Seems to be working on windows.
This commit is contained in:
parent
e57f9e9964
commit
6dc9c1096a
5 changed files with 12 additions and 10 deletions
|
@ -228,10 +228,12 @@ static int meth_connect(lua_State *L)
|
|||
|
||||
static int meth_connected(lua_State *L)
|
||||
{
|
||||
p_tcp tcp;
|
||||
p_tcp tcp = (p_tcp) aux_checkclass(L, "tcp{master}", 1);
|
||||
int err;
|
||||
tcp = (p_tcp) aux_checkclass(L, "tcp{master}", 1);
|
||||
err = sock_connected(&tcp->sock, &tcp->tm);
|
||||
t_tm tm;
|
||||
tm_init(&tm, 0.1, -1);
|
||||
tm_markstart(&tm);
|
||||
err = sock_connected(&tcp->sock, &tm);
|
||||
if (err != IO_DONE) {
|
||||
lua_pushnil(L);
|
||||
lua_pushstring(L, sock_strerror(err));
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue