diff options
author | Matt Johnston <matt@ucc.asn.au> | 2015-02-26 23:43:12 +0800 |
---|---|---|
committer | Matt Johnston <matt@ucc.asn.au> | 2015-02-26 23:43:12 +0800 |
commit | ef04e65bdc3d5979ac1813878f0b0f62990f8257 (patch) | |
tree | a45be3ba7dd1627c14d657a68763403fef58f120 | |
parent | a2d8cf3df607ede1cfb30dbefdc4fc9d1c6d4bf5 (diff) | |
download | dropbear-ef04e65bdc3d5979ac1813878f0b0f62990f8257.tar.gz |
ignore any sendmsg() errors
-rw-r--r-- | netio.c | 6 |
1 files changed, 4 insertions, 2 deletions
@@ -103,8 +103,10 @@ static void connect_try_next(struct dropbear_progress_connection *c) { message.msg_iov = packet_queue_to_iovec(c->writequeue, &iovlen); message.msg_iovlen = iovlen; res = sendmsg(c->sock, &message, MSG_FASTOPEN); - if (res < 0 && errno == EOPNOTSUPP) { - TRACE(("Fastopen not supported")); + if (res < 0) { + /* Not entirely sure which kind of errors are normal - 2.6.32 seems to + return EPIPE for any (nonblocking?) sendmsg(). just fall back */ + TRACE(("sendmsg tcp_fastopen failed, falling back. %s", strerror(errno))); /* No kernel MSG_FASTOPEN support. Fall back below */ fastopen = 0; /* Set to NULL to avoid trying again */ |