Select function call

Eliot W Dudley edudley@servtech.com
Sat Feb 1 02:39:00 GMT 1997


Unfortunatey select(2), the foundation and sine qua non of event driven
Unix applications, is not yet fully implemented.  This wouldn't be so bad
if MS hadn't come along and polluted the entire BSD namespace with
marauding impostors.  Jeremy's (jra@cynnus) select() in the CygWin32
release is the best I've seen so far, it's just not done yet.  I've been
trying to find the time to learn enough to help out in this area, but more
important issues like text vs. binary mode keep cropping up.

>From  src/winsup/select.cc:

  /*
   * This is the tricky case. We have sockets and handles used, with
   * a timeout value. Win32 cannot select on both because of the accept
   * problem. We must spawn a thread to handle one of the waits and
   * cascade it up to the other wait.
   */
  /* FIXME !!!! For now just punt - write this SOON !!!! */    

> From: Ron Forrester <Ron@OrCAD.com>
> 
> Someone else may confirm/deny this, but I believe select() is currently
> broken when used on different types of handles (i.e. combination of
> network and stdin for instance).
> 
> >From:	Larry Gerhardstein [SMTP:larry@3-cities.com]
> >
> >Does the select() function call work in Cygnus?  According to online
> >information and FAQ, I am led to believe it should.
> >
> >A program which I am attempting to port to Cygnus calls select() to
> >multiplex standard-in and a network socket.  The network connect, and
> >I/O over the socket works.  However, the value returned by select()
> >always is -1 and the value in errno is 1 (EPERM), both on NT 3.51 and

-
For help on using this list, send a message to
"gnu-win32-request@cygnus.com" with one line of text: "help".



More information about the Cygwin mailing list