diff options
author | Bryan Drewery <bdrewery@FreeBSD.org> | 2014-12-19 02:17:30 +0000 |
---|---|---|
committer | Bryan Drewery <bdrewery@FreeBSD.org> | 2014-12-19 02:17:30 +0000 |
commit | 46bdb81107d91a0d9b14ec126bde59114db1aa75 (patch) | |
tree | b691cbbefdcf080863e7bc603ef7df629e104a43 /net/tsocks/files/patch-tsocks.c | |
parent | Make default target triple match base clang. (diff) |
- Handle EISCONN
PR: ports/196115
Submitted by: Anthony Cornehl <accornehl@fastmail.fm>
Notes
Notes:
svn path=/head/; revision=374938
Diffstat (limited to 'net/tsocks/files/patch-tsocks.c')
-rw-r--r-- | net/tsocks/files/patch-tsocks.c | 19 |
1 files changed, 19 insertions, 0 deletions
diff --git a/net/tsocks/files/patch-tsocks.c b/net/tsocks/files/patch-tsocks.c new file mode 100644 index 000000000000..7d5b4984dbdd --- /dev/null +++ b/net/tsocks/files/patch-tsocks.c @@ -0,0 +1,19 @@ +--- tsocks.c.orig 2014-12-19 02:01:24 UTC ++++ tsocks.c +@@ -852,7 +852,7 @@ static int connect_server(struct connreq + sizeof(conn->serveraddr)); + + show_msg(MSGDEBUG, "Connect returned %d, errno is %d\n", rc, errno); +- if (rc) { ++ if (rc && errno != EISCONN) { + if (errno != EINPROGRESS) { + show_msg(MSGERR, "Error %d attempting to connect to SOCKS " + "server (%s)\n", errno, strerror(errno)); +@@ -862,6 +862,7 @@ static int connect_server(struct connreq + conn->state = CONNECTING; + } + } else { ++ rc = 0; + show_msg(MSGDEBUG, "Socket %d connected to SOCKS server\n", conn->sockid); + conn->state = CONNECTED; + } |