# HG changeset patch # User Matt Johnston # Date 1429015434 -28800 # Node ID d92597ef089e2fabc56e2e21a47dbc2f18a9c0af # Parent cc6116cc0b5cc1062e6ffd8b5d53d2c54f3c2630 fastopen code was totally broken diff -r cc6116cc0b5c -r d92597ef089e netio.c --- a/netio.c Sat Mar 21 22:43:08 2015 +0800 +++ b/netio.c Tue Apr 14 20:43:54 2015 +0800 @@ -72,7 +72,6 @@ int fastopen = 0; #ifdef DROPBEAR_TCP_FAST_OPEN struct msghdr message; - struct iovec message; #endif for (r = c->res_iter; r; r = r->ai_next) @@ -102,9 +101,9 @@ if (c->writequeue) { /* 6 is arbitrary, enough to hold initial packets */ int iovlen = 6; /* Linux msg_iovlen is a size_t */ - struct iov[6]; + struct iovec iov[6]; packet_queue_to_iovec(c->writequeue, iov, &iovlen); - message.msg_iov = &iov; + message.msg_iov = iov; message.msg_iovlen = iovlen; res = sendmsg(c->sock, &message, MSG_FASTOPEN); if (res < 0 && errno != EINPROGRESS) {