diff options
| author | 2003-07-09 22:03:15 +0000 | |
|---|---|---|
| committer | 2003-07-09 22:03:15 +0000 | |
| commit | 85f7599b374a41ec5d11acfae514c94850bbe1e3 (patch) | |
| tree | 1f5b2bb57030ac7b16fa1c884fd220555bcb3944 /sys/netinet/udp_usrreq.c | |
| parent | open() is not ANSI; (diff) | |
| download | wireguard-openbsd-85f7599b374a41ec5d11acfae514c94850bbe1e3.tar.xz wireguard-openbsd-85f7599b374a41ec5d11acfae514c94850bbe1e3.zip | |
do not flip ip_len/ip_off in netinet stack. deraadt ok.
(please test, especially PF portion)
Diffstat (limited to 'sys/netinet/udp_usrreq.c')
| -rw-r--r-- | sys/netinet/udp_usrreq.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/sys/netinet/udp_usrreq.c b/sys/netinet/udp_usrreq.c index 5f726dff5fb..9e5842d6087 100644 --- a/sys/netinet/udp_usrreq.c +++ b/sys/netinet/udp_usrreq.c @@ -1,4 +1,4 @@ -/* $OpenBSD: udp_usrreq.c,v 1.90 2003/06/02 23:28:15 millert Exp $ */ +/* $OpenBSD: udp_usrreq.c,v 1.91 2003/07/09 22:03:16 itojun Exp $ */ /* $NetBSD: udp_usrreq.c,v 1.28 1996/03/16 23:54:03 christos Exp $ */ /* @@ -949,7 +949,7 @@ udp_output(struct mbuf *m, ...) sizeof (struct udphdr) + IPPROTO_UDP)); } else ui->ui_sum = 0; - ((struct ip *)ui)->ip_len = sizeof (struct udpiphdr) + len; + ((struct ip *)ui)->ip_len = htons(sizeof (struct udpiphdr) + len); ((struct ip *)ui)->ip_ttl = inp->inp_ip.ip_ttl; ((struct ip *)ui)->ip_tos = inp->inp_ip.ip_tos; |
