aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--slirp/tcp.h2
-rw-r--r--slirp/tcp_subr.c2
2 files changed, 3 insertions, 1 deletions
diff --git a/slirp/tcp.h b/slirp/tcp.h
index cd7e891..0cd3ab3 100644
--- a/slirp/tcp.h
+++ b/slirp/tcp.h
@@ -112,7 +112,7 @@ struct tcphdr {
/*
* User-settable options (used with setsockopt).
*/
-/* #define TCP_NODELAY 0x01 */ /* don't delay send to coalesce packets */
+#define TCP_NODELAY 0x01 /* don't delay send to coalesce packets */
/* #define TCP_MAXSEG 0x02 */ /* set maximum segment size */
/*
diff --git a/slirp/tcp_subr.c b/slirp/tcp_subr.c
index e66987e..2526bff 100644
--- a/slirp/tcp_subr.c
+++ b/slirp/tcp_subr.c
@@ -499,6 +499,8 @@ tcp_connect(inso)
setsockopt(s,SOL_SOCKET,SO_REUSEADDR,(char *)&opt,sizeof(int));
opt = 1;
setsockopt(s,SOL_SOCKET,SO_OOBINLINE,(char *)&opt,sizeof(int));
+ opt = 1;
+ setsockopt(s,IPPROTO_TCP,TCP_NODELAY,(char *)&opt,sizeof(int));
so->so_fport = addr.sin_port;
so->so_faddr = addr.sin_addr;