On 04/01/2017 17:45, Eric Blake wrote: >> -#ifdef WIN32 >> - WSAEventSelect(sioc->fd, ioc->event, >> - FD_READ | FD_ACCEPT | FD_CLOSE | >> - FD_CONNECT | FD_WRITE | FD_OOB); >> -#endif >> } >> return 0; > How does this hunk fit in? > >> +++ b/io/channel-watch.c >> @@ -285,6 +285,12 @@ GSource *qio_channel_create_socket_watch(QIOChannel >> *ioc, >> GSource *source; >> QIOChannelSocketSource *ssource; >> >> +#ifdef WIN32 >> + WSAEventSelect(socket, ioc->event, >> + FD_READ | FD_ACCEPT | FD_CLOSE | >> + FD_CONNECT | FD_WRITE | FD_OOB); >> +#endif >> + > Is it that you're moving it, now that the ability to associate handlers > lets you have more fine-grained control on when to adjust the properties?
Yes, I'm setting the event here because aio_set_fd_handler can also call WSAEventSelect, and only one event can be in use at a time. So you cannot use qio_channel_create_socket_watch and qio_channel_yield at the same time, but you can switch from one to the other. Paolo