[PATCH 2/9] server: pending asyncs should only affect FD_READ/FD_WRITE/FD_CLOSE messages

Mike Kaplinskiy mike.kaplinskiy at gmail.com
Wed Mar 24 13:34:15 CDT 2010


On Wed, Mar 24, 2010 at 2:28 PM, Alexandre Julliard <julliard at winehq.org> wrote:
> Mike Kaplinskiy <mike.kaplinskiy at gmail.com> writes:
>
>> ---
>>  server/async.c |    8 ++++++++
>>  server/file.h  |    1 +
>>  server/sock.c  |   26 +++++++++++---------------
>>  3 files changed, 20 insertions(+), 15 deletions(-)
>
> This doesn't look right. You shouldn't ignore POLLIN/POLLOUT, they
> shouldn't have been selected in the first place. If you do get them you
> have to do something with them and unselect them.
>
> --
> Alexandre Julliard
> julliard at winehq.org
>

POLLIN/POLLOUT are selected if we have pending asyncs (as they should
be), but we shouldn't add these as pending events since the associated
overlapped operations aren't done yet. We can't say for sure if we
should notify about these events or not until the async is done and
reselects the socket (where we would get another event if need be).

It's basically the more correct version of not signaling events when
we have asyncs pending.

Mike.



More information about the wine-devel mailing list