diff --git a/BasiliskII/src/slirp/VERSION b/BasiliskII/src/slirp/VERSION index 46c623c3..353ad940 100644 --- a/BasiliskII/src/slirp/VERSION +++ b/BasiliskII/src/slirp/VERSION @@ -1 +1 @@ -qemu 0.8.2 (2006/07/14) +qemu 0.9.0 (2007/02/05) diff --git a/BasiliskII/src/slirp/tcp.h b/BasiliskII/src/slirp/tcp.h index 72fb95a4..ed878203 100644 --- a/BasiliskII/src/slirp/tcp.h +++ b/BasiliskII/src/slirp/tcp.h @@ -119,8 +119,14 @@ struct tcphdr { /* * User-settable options (used with setsockopt). + * + * We don't use the system headers on unix because we have conflicting + * local structures. We can't avoid the system definitions on Windows, + * so we undefine them. */ -/* #define TCP_NODELAY 0x01 */ /* don't delay send to coalesce packets */ +#undef TCP_NODELAY +#define TCP_NODELAY 0x01 /* don't delay send to coalesce packets */ +#undef TCP_MAXSEG /* #define TCP_MAXSEG 0x02 */ /* set maximum segment size */ /* diff --git a/BasiliskII/src/slirp/tcp_subr.c b/BasiliskII/src/slirp/tcp_subr.c index cd6748f1..41fa8eed 100644 --- a/BasiliskII/src/slirp/tcp_subr.c +++ b/BasiliskII/src/slirp/tcp_subr.c @@ -500,6 +500,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; diff --git a/BasiliskII/src/slirp/udp.c b/BasiliskII/src/slirp/udp.c index 7ccca1eb..723a49c1 100644 --- a/BasiliskII/src/slirp/udp.c +++ b/BasiliskII/src/slirp/udp.c @@ -205,8 +205,6 @@ udp_input(m, iphlen) /* udp_last_so = so; */ so->so_laddr = ip->ip_src; so->so_lport = uh->uh_sport; - so->so_faddr = ip->ip_dst; /* XXX */ - so->so_fport = uh->uh_dport; /* XXX */ if ((so->so_iptos = udp_tos(so)) == 0) so->so_iptos = ip->ip_tos; @@ -217,6 +215,9 @@ udp_input(m, iphlen) */ } + so->so_faddr = ip->ip_dst; /* XXX */ + so->so_fport = uh->uh_dport; /* XXX */ + iphlen += sizeof(struct udphdr); m->m_len -= iphlen; m->m_data += iphlen;