Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/netbsd-8]: src/sys/netipsec Pull up following revision(s) (requested by ...



details:   https://anonhg.NetBSD.org/src/rev/74348cec1625
branches:  netbsd-8
changeset: 851528:74348cec1625
user:      martin <martin%NetBSD.org@localhost>
date:      Fri Mar 30 11:50:56 2018 +0000

description:
Pull up following revision(s) (requested by maxv in ticket #669):

        sys/netipsec/ipsec.c: revision 1.134

Fix ipsec4_get_ulp(). We should do "goto done" instead of "return",
otherwise the port fields of spidx are uninitialized.

ok mlelstv@

diffstat:

 sys/netipsec/ipsec.c |  6 +++---
 1 files changed, 3 insertions(+), 3 deletions(-)

diffs (27 lines):

diff -r 63d7e63103d4 -r 74348cec1625 sys/netipsec/ipsec.c
--- a/sys/netipsec/ipsec.c      Fri Mar 30 11:45:58 2018 +0000
+++ b/sys/netipsec/ipsec.c      Fri Mar 30 11:50:56 2018 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: ipsec.c,v 1.99.2.4 2018/02/16 16:35:18 martin Exp $    */
+/*     $NetBSD: ipsec.c,v 1.99.2.5 2018/03/30 11:50:56 martin Exp $    */
 /*     $FreeBSD: /usr/local/www/cvsroot/FreeBSD/src/sys/netipsec/ipsec.c,v 1.2.2.2 2003/07/01 01:38:13 sam Exp $       */
 /*     $KAME: ipsec.c,v 1.103 2001/05/24 07:14:18 sakane Exp $ */
 
@@ -32,7 +32,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: ipsec.c,v 1.99.2.4 2018/02/16 16:35:18 martin Exp $");
+__KERNEL_RCSID(0, "$NetBSD: ipsec.c,v 1.99.2.5 2018/03/30 11:50:56 martin Exp $");
 
 /*
  * IPsec controller part.
@@ -1070,7 +1070,7 @@
                case IPPROTO_ICMP:
                        spidx->ul_proto = nxt;
                        if (off + sizeof(struct icmp) > m->m_pkthdr.len)
-                               return;
+                               goto done;
                        m_copydata(m, off, sizeof(icmph), &icmph);
                        ((struct sockaddr_in *)&spidx->src)->sin_port =
                            htons((uint16_t)icmph.icmp_type);



Home | Main Index | Thread Index | Old Index