windows [Re: Review of gnio, round 2]



I feel like, as much as possible, GSocket should behave the same on
Linux and Windows. So I'm dubious about a few things...

blocking/non-blocking: "on Windows it is not possible to read the
non-blocking property of a socket so it won't be reliably detected", and
"on windows any call to g_socket_create_source(),
g_socket_condition_check(), or g_socket_condition_wait() will
automatically enable non-blocking mode". Yuck! Would it be possible to
just always set winsock sockets to non-blocking mode, and implement
GSocket's blocking flag entirely at the GSocket level, by calling
g_socket_condition_wait() internally at the right times if
socket->priv->blocking is set?

g_socket_set_reuse_address: Huh? I'd thought we agreed that this should
always be set on unix, and never on windows, and people can use system
calls if they need the other behavior. This is essentially two
completely different methods on unix and windows right now...

GSocketControlMessage: yeah, there's nothing that can be done here, but
that's probably OK.

-- Dan


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]