[Date Prev][Date Next][Thread Prev][Thread Next]
- Subject: Re: Does it make sense to add general file descriptor support to LuaSocket 2.0?
- From: diego@...
- Date: Wed, 9 Jun 2004 18:22:59 -0400 (EDT)
> Does this actually work in a platform independant way? ie, on Windows?
Nope. That is why I don't support it straight from the box.
Socket objects are special animals on Windows, and the select
function doesn't work on file descriptors.
Cygwin's implementation actually sorts descriptors by type and spawns
one thread to wait on each type of descriptor. I am *not* about to do
this in LuaSocket. :o)
However, it seems unfair that people working on Unix should suffer
because of this. Therefore, if you can provide LuaSocket's select with a
file descriptor, it will trust you and pass it to the underlying select.
Once I am done with LuaSocket, I will go back to LuaThreads which I have
neglected for a long time. When I get there, we should come back to this
topic and see what can be done (not much, I am afraid).