Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. =================================================================== RCS file: /ftp/cvs/cvsroot/src/sys/netinet/udp_usrreq.c,v retrieving revision 1.93.4.2 retrieving revision 1.94 diff -u -p -r1.93.4.2 -r1.94 --- src/sys/netinet/udp_usrreq.c 2004/03/31 20:10:29 1.93.4.2 +++ src/sys/netinet/udp_usrreq.c 2002/06/09 16:33:45 1.94 @@ -1,9 +1,9 @@ -/* $NetBSD: udp_usrreq.c,v 1.93.4.2 2004/03/31 20:10:29 tron Exp $ */ +/* $NetBSD: udp_usrreq.c,v 1.94 2002/06/09 16:33:45 itojun Exp $ */ /* * Copyright (C) 1995, 1996, 1997, and 1998 WIDE Project. * All rights reserved. - * + * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions * are met: @@ -15,7 +15,7 @@ * 3. Neither the name of the project nor the names of its contributors * may be used to endorse or promote products derived from this software * without specific prior written permission. - * + * * THIS SOFTWARE IS PROVIDED BY THE PROJECT AND CONTRIBUTORS ``AS IS'' AND * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE @@ -65,7 +65,7 @@ */ #include -__KERNEL_RCSID(0, "$NetBSD: udp_usrreq.c,v 1.93.4.2 2004/03/31 20:10:29 tron Exp $"); +__KERNEL_RCSID(0, "$NetBSD: udp_usrreq.c,v 1.94 2002/06/09 16:33:45 itojun Exp $"); #include "opt_inet.h" #include "opt_ipsec.h" @@ -445,11 +445,9 @@ udp6_input(mp, offp, proto) /* * Checksum extended UDP header and data. */ - if (uh->uh_sum == 0) { + if (uh->uh_sum == 0) udp6stat.udp6s_nosum++; - goto bad; - } - if (in6_cksum(m, IPPROTO_UDP, off, ulen) != 0) { + else if (in6_cksum(m, IPPROTO_UDP, off, ulen) != 0) { udp6stat.udp6s_badsum++; goto bad; } @@ -1139,7 +1137,7 @@ udp_sysctl(name, namelen, oldp, oldlenp, return (sysctl_int(oldp, oldlenp, newp, newlen, &udp_sendspace)); case UDPCTL_RECVSPACE: - return (sysctl_int(oldp, oldlenp, newp, newlen, + return (sysctl_int(oldp, oldlenp, newp, newlen, &udp_recvspace)); default: return (ENOPROTOOPT);