[Date Prev][Date Next][Thread Prev][Thread Next]
- Subject: RE: luasocket and selecting from files.
- From: Thijs Schreijer <thijs@...>
- Date: Wed, 1 Jul 2015 12:33:11 +0000
> >> Is there any working code out there doing this?
> > For files? I don't know, but it would be similar with files (as
> > are file handles).
> I was thinking code preparing a file handle for serving with luasocket.
> There seems to be some weird dancing involved with creating a connected
> socket, replacing its fd, then invalidating something setting a fd of
> -1, etc.
LuaSec does this, but its result is still a handle for a socket. But it has some magic in setting the fd and invalidating the original.