Subject: RE: src questions, test cases?
From: [email-masked] (Sergey Okhapkin)

22 Oct 1997 00:55:01 -0700
Message-ID: <[email-masked]>
To: "[email-masked]" <[email-masked]>,
        "'Tim Newsham'"
	 <[email-masked]>

Tim Newsham wrote:
>
>
> I have a couple of questions about cygwin.dll (winsup) src:
>
>  - why does select iterate over all the file descriptors instead
>    of just the ones set in the bit vectors?

Select iterates over first n (the first argument of select) file 
descriptors set in one of fd_set masks.

>
>  - why does select open up a stream socket after firing off the
>    select thread?

To force select thread to exit by closing this socket when an event occured 
on non-socket handle.

>
>  - Couldn't asynchronous operations be used to select on sockets
>    instead of firing off a seperate thread?

This case we must create a thread with a window to wait for socket events. 
Also, WSAAsyncSelect automatically sets the socket unblocked, so we'll need 
to care about. More harmness than goodness... Using winsock 2 instead of 
winsock 1.1 will be more suitable with cygwin needs, but Windows 95 doesn't 
have built in support for ws 2.

>
>  - Is there any way of asynchronously checking for data on a pipe?

No way for anonymous pipes :-( My additions to b18 select() makes a polling 
select on pipes with 10ms interval. *sigh*

--
Sergey Okhapkin, http://www.lexa.ru/sos
Moscow, Russia
Looking for a job.

-
For help on using this list (especially unsubscribing), send a message to
"[email-masked]" with one line of text: "help".