Mail Archives: cygwin/2006/10/09/08:39:54
On Oct 9 12:04, Peter Ekberg wrote:
> On Mon, Oct 09, 2006 at 10:55:18AM +0200, Corinna Vinschen wrote:
> > To implement a POSIX select function which allows to select on
> > any descriptor one needs to implement it specificially for each known,
> > resp. useful file type. Naturally this won't work with a generic
> > Windows handle since Cygein doesn't know what it represents. So Cygwin
> > is unable to provide a matching select function.
>
> I assumed that cygwin as a last step issued a WaitFor... on the underlying
> win32 handles associated with the fds in its select implementation. Perhaps
> this assumption was wrong? But if not, it would be neat to somehow add an
> extra win32 handle to the array, that would break out of the cygwin select
> when the win32 handle is signaled.
Take a look into winsup/cygwin/select.cc. There's no generic way to
select on an arbitrary Windows handle without knowledge about its task.
Selecting manually, for instance by creating a thread which calls WFMO,
is the only useful choice, IMHO.
Corinna
--
Corinna Vinschen Please, send mails regarding Cygwin to
Cygwin Project Co-Leader cygwin AT cygwin DOT com
Red Hat
--
Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple
Problem reports: http://cygwin.com/problems.html
Documentation: http://cygwin.com/docs.html
FAQ: http://cygwin.com/faq/
- Raw text -