Source-Changes-HG archive

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

[src/netbsd-6-1]: src/sys/netinet6 Ooops, remainder of Ticket #1523, accident...



details:   https://anonhg.NetBSD.org/src/rev/6261526706ea
branches:  netbsd-6-1
changeset: 776286:6261526706ea
user:      martin <martin%NetBSD.org@localhost>
date:      Tue Jan 30 22:10:56 2018 +0000

description:
Ooops, remainder of Ticket #1523, accidently not commited previously

diffstat:

 sys/netinet6/ah_input.c     |  7 ++++---
 sys/netinet6/esp_input.c    |  7 ++++---
 sys/netinet6/ipcomp_input.c |  7 ++++---
 3 files changed, 12 insertions(+), 9 deletions(-)

diffs (84 lines):

diff -r 9d0e6913fe67 -r 6261526706ea sys/netinet6/ah_input.c
--- a/sys/netinet6/ah_input.c   Tue Jan 30 18:46:45 2018 +0000
+++ b/sys/netinet6/ah_input.c   Tue Jan 30 22:10:56 2018 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: ah_input.c,v 1.59 2011/07/17 20:54:53 joerg Exp $      */
+/*     $NetBSD: ah_input.c,v 1.59.14.1 2018/01/30 22:10:56 martin Exp $        */
 /*     $KAME: ah_input.c,v 1.64 2001/09/04 08:43:19 itojun Exp $       */
 
 /*
@@ -35,7 +35,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: ah_input.c,v 1.59 2011/07/17 20:54:53 joerg Exp $");
+__KERNEL_RCSID(0, "$NetBSD: ah_input.c,v 1.59.14.1 2018/01/30 22:10:56 martin Exp $");
 
 #include "opt_inet.h"
 #include "opt_ipsec.h"
@@ -858,7 +858,8 @@
                 * next header field of the previous header.
                 * This is necessary because AH will be stripped off below.
                 */
-               prvnxtp = ip6_get_prevhdr(m, off); /* XXX */
+               const int prvnxt = ip6_get_prevhdr(m, off);
+               prvnxtp = (mtod(m, u_int8_t *) + prvnxt); /* XXX */
                *prvnxtp = nxt;
 
                ip6 = mtod(m, struct ip6_hdr *);
diff -r 9d0e6913fe67 -r 6261526706ea sys/netinet6/esp_input.c
--- a/sys/netinet6/esp_input.c  Tue Jan 30 18:46:45 2018 +0000
+++ b/sys/netinet6/esp_input.c  Tue Jan 30 22:10:56 2018 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: esp_input.c,v 1.50 2011/07/17 20:54:53 joerg Exp $     */
+/*     $NetBSD: esp_input.c,v 1.50.14.1 2018/01/30 22:10:56 martin Exp $       */
 /*     $KAME: esp_input.c,v 1.60 2001/09/04 08:43:19 itojun Exp $      */
 
 /*
@@ -35,7 +35,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: esp_input.c,v 1.50 2011/07/17 20:54:53 joerg Exp $");
+__KERNEL_RCSID(0, "$NetBSD: esp_input.c,v 1.50.14.1 2018/01/30 22:10:56 martin Exp $");
 
 #include "opt_inet.h"
 #include "opt_ipsec.h"
@@ -834,7 +834,8 @@
                /*
                 * Set the next header field of the previous header correctly.
                 */
-               prvnxtp = ip6_get_prevhdr(m, off); /* XXX */
+               const int prvnxt = ip6_get_prevhdr(m, off);
+               prvnxtp = (mtod(m, u_int8_t *) + prvnxt); /* XXX */
                *prvnxtp = nxt;
 
                stripsiz = esplen + ivlen;
diff -r 9d0e6913fe67 -r 6261526706ea sys/netinet6/ipcomp_input.c
--- a/sys/netinet6/ipcomp_input.c       Tue Jan 30 18:46:45 2018 +0000
+++ b/sys/netinet6/ipcomp_input.c       Tue Jan 30 22:10:56 2018 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: ipcomp_input.c,v 1.38 2011/07/17 20:54:53 joerg Exp $  */
+/*     $NetBSD: ipcomp_input.c,v 1.38.14.1 2018/01/30 22:10:56 martin Exp $    */
 /*     $KAME: ipcomp_input.c,v 1.29 2001/09/04 08:43:19 itojun Exp $   */
 
 /*
@@ -35,7 +35,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: ipcomp_input.c,v 1.38 2011/07/17 20:54:53 joerg Exp $");
+__KERNEL_RCSID(0, "$NetBSD: ipcomp_input.c,v 1.38.14.1 2018/01/30 22:10:56 martin Exp $");
 
 #include "opt_inet.h"
 #include "opt_ipsec.h"
@@ -352,7 +352,8 @@
        m->m_flags |= M_DECRYPTED;
 
        /* update next header field */
-       prvnxtp = ip6_get_prevhdr(m, off);
+       const int prvnxt = ip6_get_prevhdr(m, off);
+       prvnxtp = (mtod(m, u_int8_t *) + prvnxt); /* XXX */
        *prvnxtp = nxt;
 
        /*



Home | Main Index | Thread Index | Old Index