diff options
Diffstat (limited to 'winsup/cygwin/select.cc')
-rw-r--r-- | winsup/cygwin/select.cc | 15 |
1 files changed, 8 insertions, 7 deletions
diff --git a/winsup/cygwin/select.cc b/winsup/cygwin/select.cc index 8b77d2a..a884ea1 100644 --- a/winsup/cygwin/select.cc +++ b/winsup/cygwin/select.cc @@ -338,11 +338,10 @@ set_bits (select_record *me, fd_set *readfds, fd_set *writefds, UNIX_FD_SET (me->fd, writefds); if (me->except_on_write && (sock = me->fh->is_socket ())) { - /* eid credential transaction on successful non-blocking connect. - Since the read bit indicates an error, don't start transaction - if it's set. */ - if (!me->read_ready && sock->connect_state () == connect_pending) - sock->eid_connect (); + /* Special AF_LOCAL handling. */ + if (!me->read_ready && sock->connect_state () == connect_pending + && sock->af_local_connect () && me->read_selected) + UNIX_FD_SET (me->fd, readfds); sock->connect_state (connected); } ready++; @@ -354,8 +353,10 @@ set_bits (select_record *me, fd_set *readfds, fd_set *writefds, UNIX_FD_SET (me->fd, writefds); if ((sock = me->fh->is_socket ())) { - if (!me->read_ready && sock->connect_state () == connect_pending) - sock->eid_connect (); + /* Special AF_LOCAL handling. */ + if (!me->read_ready && sock->connect_state () == connect_pending + && sock->af_local_connect () && me->read_selected) + UNIX_FD_SET (me->fd, readfds); sock->connect_state (connected); } } |