From 17cac09c5eede8b40a114db4ac53cbbf5a5b84c9 Mon Sep 17 00:00:00 2001 From: bms Date: Wed, 3 Sep 2003 02:19:29 +0000 Subject: PR: kern/56343 Reviewed by: tjr Approved by: jake (mentor) --- sys/netinet/udp_usrreq.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'sys/netinet') diff --git a/sys/netinet/udp_usrreq.c b/sys/netinet/udp_usrreq.c index 6b8b87e..8cecb7b 100644 --- a/sys/netinet/udp_usrreq.c +++ b/sys/netinet/udp_usrreq.c @@ -830,7 +830,9 @@ udp_output(inp, m, addr, control, td) * Set up checksum and output datagram. */ if (udpcksum) { - ui->ui_sum = in_pseudo(ui->ui_src.s_addr, ui->ui_dst.s_addr, + if (inp->inp_flags & INP_ONESBCAST) + faddr.s_addr = INADDR_BROADCAST; + ui->ui_sum = in_pseudo(ui->ui_src.s_addr, faddr.s_addr, htons((u_short)len + sizeof(struct udphdr) + IPPROTO_UDP)); m->m_pkthdr.csum_flags = CSUM_UDP; m->m_pkthdr.csum_data = offsetof(struct udphdr, uh_sum); -- cgit v1.1