What do u thing about the Select() Function ???

Subject: What do u thing about the Select() Function ???

hello guys,

Maybe, when i want to use the recv() function, i’ve got the problem that my prozess is blocket. (its only a sample, not the problem)

And when i want to avoid this i can use for example the alarm() function.

Or i can take the Select() function.
But i have haerd that the Select function is not good for a realtime prozesses.
Is it true ???[/i]

Well, select() is a rather expensive call on QNX. I wouldn’t say you couldn’t use it for realtime work, you just have to be aware that there is some overhead and if you can live with that overhead you will be fine.

Generally I use threads instead of using select().

Or, you can, of cause, open the fd (or use ioctl to set) O_NONBLOCK, you recv()
would come back with a EWOULDBLOCK if there is no data for you.