NetBSD-Users archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
Re: select() timeout
On Fri, Feb 03, 2012 at 02:05:03PM +0200, Jukka Marin wrote:
> I was using a fixed 20 ms timeout and the protocol was working ok for most
> of the time, but sometimes I got a burst of receive timeouts. I'm not sure
> if the data is held in the tty buffers or if my timeout logic is failing yet.
>
> So, are short timeouts reliable with select()?
No, probably not. A NetBSD kernel isn't a realtime kernel.
And select(2) is a dangerous API. You should really use poll(2) or
kqueue(2) instead.
Kind regards
--
Matthias Scheler http://zhadum.org.uk/
Home |
Main Index |
Thread Index |
Old Index