1
0
mirror of https://github.com/moparisthebest/socat synced 2024-11-13 12:35:08 -05:00

TCP-CONNECT with option nonblock reported successful connect even when it was still pending

This commit is contained in:
Gerhard Rieger 2010-10-05 07:35:02 +02:00
parent e0d548df71
commit 290b62c817
2 changed files with 6 additions and 3 deletions

View File

@ -14,6 +14,9 @@ corrections:
UNIX-CONNECT did not support half-close. Thanks to Greg Hughes who UNIX-CONNECT did not support half-close. Thanks to Greg Hughes who
pointed me to that bug pointed me to that bug
TCP-CONNECT with option nonblock reported successful connect even when
it was still pending
####################### V 1.7.1.3: ####################### V 1.7.1.3:
security: security:

View File

@ -910,15 +910,15 @@ int _xioopen_connect(struct single *xfd, struct sockaddr *us, size_t uslen,
Close(xfd->fd); Close(xfd->fd);
return STAT_RETRYLATER; return STAT_RETRYLATER;
} }
} else { /* result >= 0 */
Notice1("successfully connected from local address %s",
sockaddr_info(&la.soa, themlen, infobuff, sizeof(infobuff)));
} }
applyopts_fchown(xfd->fd, opts); /* OPT_USER, OPT_GROUP */ applyopts_fchown(xfd->fd, opts); /* OPT_USER, OPT_GROUP */
applyopts(xfd->fd, opts, PH_CONNECTED); applyopts(xfd->fd, opts, PH_CONNECTED);
applyopts(xfd->fd, opts, PH_LATE); applyopts(xfd->fd, opts, PH_LATE);
Notice1("successfully connected from local address %s",
sockaddr_info(&la.soa, themlen, infobuff, sizeof(infobuff)));
return STAT_OK; return STAT_OK;
} }