lua-users home
lua-l archive

[Date Prev][Date Next][Thread Prev][Thread Next] [Date Index] [Thread Index]


Hi,

> I'm very fond of Lua5 and LuaSocket 2.0, but I have one issue that I'd
> like to address.
>
> I use Lua to monitor network communication ~and~ data coming in on a
> RS-232 port.
>
> It'd be great if I add the file descriptor for the serial port into
> the list socket.select uses.
>
> Is this crazy? If not, how much of a hack would this be to LuaSocket?

The hack is already there. The new select implementation only requires you
to provide a getfd method in the object you want to call select on. I know
this is dirty and might crash, but I am not documenting it and expecting
only people that know what they are doing (such as yourself) to use it.

[]s,
Diego.