|
Boost : |
From: Christopher Kohlhoff (chris_at_[hidden])
Date: 2006-05-08 08:40:50
Hi Peter,
Peter Dimov <pdimov_at_[hidden]> wrote:
> Christopher Kohlhoff wrote:
> > It's on my to-do list to implement true asynchronous connect
> > using ConnectEx (on Windows XP, Window Server 2003 and
> > later). When I find some time to do this, I will be able to
> > eliminate this select_reactor use and the associated socket.
>
> Probably a stupid question, but why not use
> WSAAsyncSelect/WSAEventSelect?
The WSAAsyncSelect function is part of the old Windows 3.1
socket interface and uses window messages for notification. I
don't really want to go there :)
I could use WSAEventSelect in conjunction with
WaitForMultipleObjects. It does have a 64 handle limit, whereas
select doesn't (FD_SETSIZE defaults to 64 but can be redefined),
but that may not be a problem in practice.
However, the main reason I'm using the select_reactor on Windows
over a WFMO reactor is that it reuses code. And since ConnectEx
is available on Windows XP, 2003, and all new versions moving
forward, there doesn't seem so much reason to develop a WFMO
reactor at this time.
Cheers,
Chris
Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk