[Date Prev][Date Next][Thread Prev][Thread Next]
[Date Index]
[Thread Index]
- Subject: Re: Luasocket socket.select timeout bugs?
- From: Marius Kjeldahl <marius@...>
- Date: Tue, 21 Sep 2004 20:20:53 +0200
On Tuesday 21 September 2004 20:01, Maxime Petazzoni wrote:
> > Whenever I try a simple "socket.select (nil, nil, 10)" luasocket returns
> > immediately instead of waiting 10 seconds. I'm using lua 5.0.2 and
> > luasocket 2.0 beta 2 on Gentoo Linux (on Intel).
>
> Maybe it is because of the nil table of sockets ?
> Does it work with not nil parameters ?
First of all, the "nil, nil, timeout" is a pretty "normal" way to invoke a
sub-second sleep on *ix platforms, and this is even mentioned in the
documentation.
To your question, yes, this bug triggered on a single threaded select based
server of mine (I was wondering about the high CPU usage). To make it easier
to ask the question, I tried to come up with a minimal case to share with
other people, and I guess I found a minimal test case for looking into this
bug or having other prove me wrong (i.e. something else is wrong at my end).
Regards,
Marius Kjeldahl