correct signedness mixup in pointer passing. sync w/kame

This commit is contained in:
itojun 2002-09-11 02:41:19 +00:00
parent cdb79dd4ae
commit 6dedde045a
15 changed files with 82 additions and 80 deletions

View File

@ -1,4 +1,4 @@
/* $NetBSD: ip_input.c,v 1.155 2002/08/14 00:23:31 itojun Exp $ */
/* $NetBSD: ip_input.c,v 1.156 2002/09/11 02:41:19 itojun Exp $ */
/*
* Copyright (C) 1995, 1996, 1997, and 1998 WIDE Project.
@ -102,7 +102,7 @@
*/
#include <sys/cdefs.h>
__KERNEL_RCSID(0, "$NetBSD: ip_input.c,v 1.155 2002/08/14 00:23:31 itojun Exp $");
__KERNEL_RCSID(0, "$NetBSD: ip_input.c,v 1.156 2002/09/11 02:41:19 itojun Exp $");
#include "opt_gateway.h"
#include "opt_pfil_hooks.h"
@ -192,7 +192,7 @@ int ip_forwsrcrt = IPFORWSRCRT;
int ip_directedbcast = IPDIRECTEDBCAST;
int ip_allowsrcrt = IPALLOWSRCRT;
int ip_mtudisc = IPMTUDISC;
u_int ip_mtudisc_timeout = IPMTUDISCTIMEOUT;
int ip_mtudisc_timeout = IPMTUDISCTIMEOUT;
#ifdef DIAGNOSTIC
int ipprintfs = 0;
#endif
@ -1865,6 +1865,8 @@ ip_sysctl(name, namelen, oldp, oldlenp, newp, newlen)
case IPCTL_MTUDISCTIMEOUT:
error = sysctl_int(oldp, oldlenp, newp, newlen,
&ip_mtudisc_timeout);
if (ip_mtudisc_timeout < 0)
return (EINVAL);
if (ip_mtudisc_timeout_q != NULL)
rt_timer_queue_change(ip_mtudisc_timeout_q,
ip_mtudisc_timeout);

View File

@ -1,4 +1,4 @@
/* $NetBSD: ip_var.h,v 1.48 2002/06/30 22:40:35 thorpej Exp $ */
/* $NetBSD: ip_var.h,v 1.49 2002/09/11 02:41:20 itojun Exp $ */
/*
* Copyright (c) 1982, 1986, 1993
@ -195,7 +195,7 @@ extern u_int16_t ip_id; /* ip packet ctr, for ids */
extern int ip_defttl; /* default IP ttl */
extern int ipforwarding; /* ip forwarding */
extern int ip_mtudisc; /* mtu discovery */
extern u_int ip_mtudisc_timeout; /* seconds to timeout mtu discovery */
extern int ip_mtudisc_timeout; /* seconds to timeout mtu discovery */
extern int anonportmin; /* minimum ephemeral port */
extern int anonportmax; /* maximum ephemeral port */
extern int lowportmin; /* minimum reserved port */

View File

@ -1,4 +1,4 @@
/* $NetBSD: tcp_input.c,v 1.154 2002/09/05 23:02:18 itojun Exp $ */
/* $NetBSD: tcp_input.c,v 1.155 2002/09/11 02:41:21 itojun Exp $ */
/*
* Copyright (C) 1995, 1996, 1997, and 1998 WIDE Project.
@ -152,7 +152,7 @@
*/
#include <sys/cdefs.h>
__KERNEL_RCSID(0, "$NetBSD: tcp_input.c,v 1.154 2002/09/05 23:02:18 itojun Exp $");
__KERNEL_RCSID(0, "$NetBSD: tcp_input.c,v 1.155 2002/09/11 02:41:21 itojun Exp $");
#include "opt_inet.h"
#include "opt_ipsec.h"
@ -780,7 +780,7 @@ tcp_input(m, va_alist)
struct ip6_hdr *ip6;
struct in6pcb *in6p;
#endif
caddr_t optp = NULL;
u_int8_t *optp = NULL;
int optlen = 0;
int len, tlen, toff, hdroptlen = 0;
struct tcpcb *tp = 0;
@ -986,7 +986,7 @@ tcp_input(m, va_alist)
#endif
KASSERT(TCP_HDR_ALIGNED_P(th));
optlen = off - sizeof (struct tcphdr);
optp = ((caddr_t)th) + sizeof(struct tcphdr);
optp = ((u_int8_t *)th) + sizeof(struct tcphdr);
/*
* Do quick retrieval of timestamp options ("options
* prediction?"). If timestamp is the only option and it's

View File

@ -1,4 +1,4 @@
/* $NetBSD: ah_input.c,v 1.35 2002/08/14 00:23:37 itojun Exp $ */
/* $NetBSD: ah_input.c,v 1.36 2002/09/11 02:41:22 itojun 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.35 2002/08/14 00:23:37 itojun Exp $");
__KERNEL_RCSID(0, "$NetBSD: ah_input.c,v 1.36 2002/09/11 02:41:22 itojun Exp $");
#include "opt_inet.h"
@ -919,7 +919,7 @@ ah6_input(mp, offp, proto)
/*
* strip off AH.
*/
char *prvnxtp;
u_int8_t *prvnxtp;
/*
* Copy the value of the next header field of AH to the

View File

@ -1,4 +1,4 @@
/* $NetBSD: esp_input.c,v 1.24 2002/08/21 23:12:01 itojun Exp $ */
/* $NetBSD: esp_input.c,v 1.25 2002/09/11 02:41:23 itojun 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.24 2002/08/21 23:12:01 itojun Exp $");
__KERNEL_RCSID(0, "$NetBSD: esp_input.c,v 1.25 2002/09/11 02:41:23 itojun Exp $");
#include "opt_inet.h"
@ -826,7 +826,7 @@ noreplaycheck:
* we can always compute checksum for AH correctly.
*/
size_t stripsiz;
char *prvnxtp;
u_int8_t *prvnxtp;
/*
* Set the next header field of the previous header correctly.

View File

@ -1,4 +1,4 @@
/* $NetBSD: frag6.c,v 1.20 2002/06/09 14:43:11 itojun Exp $ */
/* $NetBSD: frag6.c,v 1.21 2002/09/11 02:41:23 itojun Exp $ */
/* $KAME: frag6.c,v 1.40 2002/05/27 21:40:31 itojun Exp $ */
/*
@ -31,7 +31,7 @@
*/
#include <sys/cdefs.h>
__KERNEL_RCSID(0, "$NetBSD: frag6.c,v 1.20 2002/06/09 14:43:11 itojun Exp $");
__KERNEL_RCSID(0, "$NetBSD: frag6.c,v 1.21 2002/09/11 02:41:23 itojun Exp $");
#include <sys/param.h>
#include <sys/systm.h>
@ -570,7 +570,7 @@ insert:
* Store NXT to the original.
*/
{
char *prvnxtp = ip6_get_prevhdr(m, offset); /* XXX */
u_int8_t *prvnxtp = ip6_get_prevhdr(m, offset); /* XXX */
*prvnxtp = nxt;
}

View File

@ -1,4 +1,4 @@
/* $NetBSD: in6_ifattach.c,v 1.49 2002/06/11 07:28:06 itojun Exp $ */
/* $NetBSD: in6_ifattach.c,v 1.50 2002/09/11 02:41:24 itojun Exp $ */
/* $KAME: in6_ifattach.c,v 1.124 2001/07/18 08:32:51 jinmei Exp $ */
/*
@ -31,7 +31,7 @@
*/
#include <sys/cdefs.h>
__KERNEL_RCSID(0, "$NetBSD: in6_ifattach.c,v 1.49 2002/06/11 07:28:06 itojun Exp $");
__KERNEL_RCSID(0, "$NetBSD: in6_ifattach.c,v 1.50 2002/09/11 02:41:24 itojun Exp $");
#include <sys/param.h>
#include <sys/systm.h>
@ -103,7 +103,7 @@ get_rand_ifid(ifp, in6)
/* generate 8 bytes of pseudo-random value. */
bzero(&ctxt, sizeof(ctxt));
MD5Init(&ctxt);
MD5Update(&ctxt, hostname, hostnamelen);
MD5Update(&ctxt, (u_char *)hostname, hostnamelen);
MD5Final(digest, &ctxt);
/* assumes sizeof(digest) > sizeof(ifid) */
@ -130,7 +130,7 @@ get_hw_ifid(ifp, in6)
{
struct ifaddr *ifa;
struct sockaddr_dl *sdl;
u_int8_t *addr;
char *addr;
size_t addrlen;
static u_int8_t allzero[8] = { 0, 0, 0, 0, 0, 0, 0, 0 };
static u_int8_t allone[8] =
@ -525,8 +525,8 @@ in6_nigroup(ifp, name, namelen, sa6)
u_char *q;
MD5_CTX ctxt;
u_int8_t digest[16];
char l;
char n[64]; /* a single label must not exceed 63 chars */
u_int8_t l;
u_int8_t n[64]; /* a single label must not exceed 63 chars */
if (!namelen || !name)
return -1;
@ -537,7 +537,7 @@ in6_nigroup(ifp, name, namelen, sa6)
if (p - name > sizeof(n) - 1)
return -1; /* label too long */
l = p - name;
strncpy(n, name, l);
strncpy((char *)n, name, l);
n[(int)l] = '\0';
for (q = n; *q; q++) {
if ('A' <= *q && *q <= 'Z')

View File

@ -1,4 +1,4 @@
/* $NetBSD: ip6_input.c,v 1.57 2002/06/30 22:40:39 thorpej Exp $ */
/* $NetBSD: ip6_input.c,v 1.58 2002/09/11 02:41:25 itojun Exp $ */
/* $KAME: ip6_input.c,v 1.188 2001/03/29 05:34:31 itojun Exp $ */
/*
@ -66,7 +66,7 @@
*/
#include <sys/cdefs.h>
__KERNEL_RCSID(0, "$NetBSD: ip6_input.c,v 1.57 2002/06/30 22:40:39 thorpej Exp $");
__KERNEL_RCSID(0, "$NetBSD: ip6_input.c,v 1.58 2002/09/11 02:41:25 itojun Exp $");
#include "opt_inet.h"
#include "opt_ipsec.h"
@ -811,11 +811,11 @@ ip6_hopopts_input(plenp, rtalertp, mp, offp)
if (ip6_process_hopopts(m, (u_int8_t *)hbh + sizeof(struct ip6_hbh),
hbhlen, rtalertp, plenp) < 0)
return(-1);
return (-1);
*offp = off;
*mp = m;
return(0);
return (0);
}
/*
@ -975,14 +975,14 @@ ip6_unknown_opt(optp, m, off)
switch (IP6OPT_TYPE(*optp)) {
case IP6OPT_TYPE_SKIP: /* ignore the option */
return((int)*(optp + 1));
return ((int)*(optp + 1));
case IP6OPT_TYPE_DISCARD: /* silently discard */
m_freem(m);
return(-1);
return (-1);
case IP6OPT_TYPE_FORCEICMP: /* send ICMP even if multicasted */
ip6stat.ip6s_badoptions++;
icmp6_error(m, ICMP6_PARAM_PROB, ICMP6_PARAMPROB_OPTION, off);
return(-1);
return (-1);
case IP6OPT_TYPE_ICMP: /* send ICMP if not multicasted */
ip6stat.ip6s_badoptions++;
ip6 = mtod(m, struct ip6_hdr *);
@ -992,11 +992,11 @@ ip6_unknown_opt(optp, m, off)
else
icmp6_error(m, ICMP6_PARAM_PROB,
ICMP6_PARAMPROB_OPTION, off);
return(-1);
return (-1);
}
m_freem(m); /* XXX: NOTREACHED */
return(-1);
return (-1);
}
/*
@ -1243,7 +1243,7 @@ ip6_savecontrol(in6p, mp, ip6, m)
* carefully. Moreover, it will not be used in the near future when
* we develop `neater' mechanism to process extension headers.
*/
char *
u_int8_t *
ip6_get_prevhdr(m, off)
struct mbuf *m;
int off;
@ -1251,7 +1251,7 @@ ip6_get_prevhdr(m, off)
struct ip6_hdr *ip6 = mtod(m, struct ip6_hdr *);
if (off == sizeof(struct ip6_hdr))
return(&ip6->ip6_nxt);
return (&ip6->ip6_nxt);
else {
int len, nxt;
struct ip6_ext *ip6e = NULL;
@ -1275,7 +1275,7 @@ ip6_get_prevhdr(m, off)
nxt = ip6e->ip6e_nxt;
}
if (ip6e)
return(&ip6e->ip6e_nxt);
return (&ip6e->ip6e_nxt);
else
return NULL;
}

View File

@ -1,4 +1,4 @@
/* $NetBSD: ip6_output.c,v 1.55 2002/06/09 14:43:12 itojun Exp $ */
/* $NetBSD: ip6_output.c,v 1.56 2002/09/11 02:41:26 itojun Exp $ */
/* $KAME: ip6_output.c,v 1.172 2001/03/25 09:55:56 itojun Exp $ */
/*
@ -66,7 +66,7 @@
*/
#include <sys/cdefs.h>
__KERNEL_RCSID(0, "$NetBSD: ip6_output.c,v 1.55 2002/06/09 14:43:12 itojun Exp $");
__KERNEL_RCSID(0, "$NetBSD: ip6_output.c,v 1.56 2002/09/11 02:41:26 itojun Exp $");
#include "opt_inet.h"
#include "opt_ipsec.h"
@ -1031,7 +1031,7 @@ ip6_insert_jumboopt(exthdrs, plen)
u_int32_t plen;
{
struct mbuf *mopt;
u_char *optbuf;
u_int8_t *optbuf;
u_int32_t v;
#define JUMBOOPTLEN 8 /* length of jumbo payload option and padding */
@ -1047,7 +1047,7 @@ ip6_insert_jumboopt(exthdrs, plen)
if (mopt == 0)
return(ENOBUFS);
mopt->m_len = JUMBOOPTLEN;
optbuf = mtod(mopt, u_char *);
optbuf = mtod(mopt, u_int8_t *);
optbuf[1] = 0; /* = ((JUMBOOPTLEN) >> 3) - 1 */
exthdrs->ip6e_hbh = mopt;
} else {
@ -1088,11 +1088,11 @@ ip6_insert_jumboopt(exthdrs, plen)
n->m_len = oldoptlen + JUMBOOPTLEN;
bcopy(mtod(mopt, caddr_t), mtod(n, caddr_t),
oldoptlen);
optbuf = mtod(n, caddr_t) + oldoptlen;
optbuf = mtod(n, u_int8_t *) + oldoptlen;
m_freem(mopt);
mopt = exthdrs->ip6e_hbh = n;
} else {
optbuf = mtod(mopt, u_char *) + mopt->m_len;
optbuf = mtod(mopt, u_int8_t *) + mopt->m_len;
mopt->m_len += JUMBOOPTLEN;
}
optbuf[0] = IP6OPT_PADN;

View File

@ -1,4 +1,4 @@
/* $NetBSD: ip6_var.h,v 1.22 2002/06/30 22:40:40 thorpej Exp $ */
/* $NetBSD: ip6_var.h,v 1.23 2002/09/11 02:41:26 itojun Exp $ */
/* $KAME: ip6_var.h,v 1.33 2000/06/11 14:59:20 jinmei Exp $ */
/*
@ -254,7 +254,7 @@ void ip6intr __P((void));
void ip6_input __P((struct mbuf *));
void ip6_freemoptions __P((struct ip6_moptions *));
int ip6_unknown_opt __P((u_int8_t *, struct mbuf *, int));
char * ip6_get_prevhdr __P((struct mbuf *, int));
u_int8_t *ip6_get_prevhdr __P((struct mbuf *, int));
int ip6_nexthdr __P((struct mbuf *, int, int, int *));
int ip6_lasthdr __P((struct mbuf *, int, int, int *));
int ip6_mforward __P((struct ip6_hdr *, struct ifnet *, struct mbuf *));

View File

@ -1,4 +1,4 @@
/* $NetBSD: ipcomp_input.c,v 1.19 2002/08/14 00:23:38 itojun Exp $ */
/* $NetBSD: ipcomp_input.c,v 1.20 2002/09/11 02:41:27 itojun 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.19 2002/08/14 00:23:38 itojun Exp $");
__KERNEL_RCSID(0, "$NetBSD: ipcomp_input.c,v 1.20 2002/09/11 02:41:27 itojun Exp $");
#include "opt_inet.h"
@ -259,7 +259,7 @@ ipcomp6_input(mp, offp, proto)
int error;
size_t newlen;
struct secasvar *sav = NULL;
char *prvnxtp;
u_int8_t *prvnxtp;
m = *mp;
off = *offp;

View File

@ -1,4 +1,4 @@
/* $NetBSD: ipsec.c,v 1.65 2002/08/14 00:23:39 itojun Exp $ */
/* $NetBSD: ipsec.c,v 1.66 2002/09/11 02:41:27 itojun Exp $ */
/* $KAME: ipsec.c,v 1.136 2002/05/19 00:36:39 itojun Exp $ */
/*
@ -35,7 +35,7 @@
*/
#include <sys/cdefs.h>
__KERNEL_RCSID(0, "$NetBSD: ipsec.c,v 1.65 2002/08/14 00:23:39 itojun Exp $");
__KERNEL_RCSID(0, "$NetBSD: ipsec.c,v 1.66 2002/09/11 02:41:27 itojun Exp $");
#include "opt_inet.h"
#include "opt_ipsec.h"
@ -2237,7 +2237,7 @@ ipsec_chkreplay(seq, sav)
fr = frlast - diff / 8;
/* this packet already seen ? */
if ((replay->bitmap)[fr] & (1 << (diff % 8)))
if (replay->bitmap[fr] & (1 << (diff % 8)))
return 0;
/* out of order but good */
@ -2282,7 +2282,7 @@ ipsec_updatereplay(seq, sav)
if (replay->count == 0) {
replay->lastseq = seq;
bzero(replay->bitmap, replay->wsize);
(replay->bitmap)[frlast] = 1;
replay->bitmap[frlast] = 1;
goto ok;
}
@ -2295,11 +2295,11 @@ ipsec_updatereplay(seq, sav)
/* In window */
/* set bit for this packet */
vshiftl(replay->bitmap, diff, replay->wsize);
(replay->bitmap)[frlast] |= 1;
replay->bitmap[frlast] |= 1;
} else {
/* this packet has a "way larger" */
bzero(replay->bitmap, replay->wsize);
(replay->bitmap)[frlast] = 1;
replay->bitmap[frlast] = 1;
}
replay->lastseq = seq;
@ -2315,11 +2315,11 @@ ipsec_updatereplay(seq, sav)
fr = frlast - diff / 8;
/* this packet already seen ? */
if ((replay->bitmap)[fr] & (1 << (diff % 8)))
if (replay->bitmap[fr] & (1 << (diff % 8)))
return 1;
/* mark as seen */
(replay->bitmap)[fr] |= (1 << (diff % 8));
replay->bitmap[fr] |= (1 << (diff % 8));
/* out of order but good */
}
@ -2363,7 +2363,7 @@ vshiftl(bitmap, nbit, wsize)
for (i = 1; i < wsize; i++) {
over = (bitmap[i] >> (8 - s));
bitmap[i] <<= s;
bitmap[i-1] |= over;
bitmap[i - 1] |= over;
}
}
@ -3606,39 +3606,39 @@ ipsec_sysctl(name, namelen, oldp, oldlenp, newp, newlen)
switch (name[0]) {
case IPSECCTL_STATS:
return sysctl_struct(oldp, oldlenp, newp, newlen,
&ipsecstat, sizeof(ipsecstat));
&ipsecstat, sizeof(ipsecstat));
case IPSECCTL_DEF_POLICY:
return sysctl_int(oldp, oldlenp, newp, newlen,
&ip4_def_policy->policy);
&ip4_def_policy->policy);
case IPSECCTL_DEF_ESP_TRANSLEV:
if (newp != NULL)
ipsec_invalpcbcacheall();
return sysctl_int(oldp, oldlenp, newp, newlen,
&ip4_esp_trans_deflev);
&ip4_esp_trans_deflev);
case IPSECCTL_DEF_ESP_NETLEV:
if (newp != NULL)
ipsec_invalpcbcacheall();
return sysctl_int(oldp, oldlenp, newp, newlen,
&ip4_esp_net_deflev);
&ip4_esp_net_deflev);
case IPSECCTL_DEF_AH_TRANSLEV:
if (newp != NULL)
ipsec_invalpcbcacheall();
return sysctl_int(oldp, oldlenp, newp, newlen,
&ip4_ah_trans_deflev);
&ip4_ah_trans_deflev);
case IPSECCTL_DEF_AH_NETLEV:
if (newp != NULL)
ipsec_invalpcbcacheall();
return sysctl_int(oldp, oldlenp, newp, newlen,
&ip4_ah_net_deflev);
&ip4_ah_net_deflev);
case IPSECCTL_AH_CLEARTOS:
return sysctl_int(oldp, oldlenp, newp, newlen,
&ip4_ah_cleartos);
&ip4_ah_cleartos);
case IPSECCTL_AH_OFFSETMASK:
return sysctl_int(oldp, oldlenp, newp, newlen,
&ip4_ah_offsetmask);
&ip4_ah_offsetmask);
case IPSECCTL_DFBIT:
return sysctl_int(oldp, oldlenp, newp, newlen,
&ip4_ipsec_dfbit);
&ip4_ipsec_dfbit);
case IPSECCTL_ECN:
return sysctl_int(oldp, oldlenp, newp, newlen, &ip4_ipsec_ecn);
case IPSECCTL_DEBUG:
@ -3708,30 +3708,30 @@ ipsec6_sysctl(name, namelen, oldp, oldlenp, newp, newlen)
switch (name[0]) {
case IPSECCTL_STATS:
return sysctl_struct(oldp, oldlenp, newp, newlen,
&ipsec6stat, sizeof(ipsec6stat));
&ipsec6stat, sizeof(ipsec6stat));
case IPSECCTL_DEF_POLICY:
return sysctl_int(oldp, oldlenp, newp, newlen,
&ip6_def_policy->policy);
&ip6_def_policy->policy);
case IPSECCTL_DEF_ESP_TRANSLEV:
if (newp != NULL)
ipsec_invalpcbcacheall();
return sysctl_int(oldp, oldlenp, newp, newlen,
&ip6_esp_trans_deflev);
&ip6_esp_trans_deflev);
case IPSECCTL_DEF_ESP_NETLEV:
if (newp != NULL)
ipsec_invalpcbcacheall();
return sysctl_int(oldp, oldlenp, newp, newlen,
&ip6_esp_net_deflev);
&ip6_esp_net_deflev);
case IPSECCTL_DEF_AH_TRANSLEV:
if (newp != NULL)
ipsec_invalpcbcacheall();
return sysctl_int(oldp, oldlenp, newp, newlen,
&ip6_ah_trans_deflev);
&ip6_ah_trans_deflev);
case IPSECCTL_DEF_AH_NETLEV:
if (newp != NULL)
ipsec_invalpcbcacheall();
return sysctl_int(oldp, oldlenp, newp, newlen,
&ip6_ah_net_deflev);
&ip6_ah_net_deflev);
case IPSECCTL_ECN:
return sysctl_int(oldp, oldlenp, newp, newlen, &ip6_ipsec_ecn);
case IPSECCTL_DEBUG:

View File

@ -1,4 +1,4 @@
/* $NetBSD: ipsec.h,v 1.29 2002/06/12 17:56:45 itojun Exp $ */
/* $NetBSD: ipsec.h,v 1.30 2002/09/11 02:41:28 itojun Exp $ */
/* $KAME: ipsec.h,v 1.51 2001/08/05 04:52:58 itojun Exp $ */
/*
@ -81,7 +81,7 @@ struct secpolicy {
#define IPSEC_SPSTATE_DEAD 0
#define IPSEC_SPSTATE_ALIVE 1
u_int policy; /* DISCARD, NONE or IPSEC, see keyv2.h */
int policy; /* DISCARD, NONE or IPSEC, see keyv2.h */
struct ipsecrequest *req;
/* pointer to the ipsec request tree, */
/* if policy == IPSEC else this value == NULL.*/

View File

@ -1,4 +1,4 @@
/* $NetBSD: raw_ip6.c,v 1.49 2002/07/20 21:11:55 itojun Exp $ */
/* $NetBSD: raw_ip6.c,v 1.50 2002/09/11 02:41:28 itojun Exp $ */
/* $KAME: raw_ip6.c,v 1.82 2001/07/23 18:57:56 jinmei Exp $ */
/*
@ -66,7 +66,7 @@
*/
#include <sys/cdefs.h>
__KERNEL_RCSID(0, "$NetBSD: raw_ip6.c,v 1.49 2002/07/20 21:11:55 itojun Exp $");
__KERNEL_RCSID(0, "$NetBSD: raw_ip6.c,v 1.50 2002/09/11 02:41:28 itojun Exp $");
#include "opt_ipsec.h"
@ -254,11 +254,11 @@ rip6_input(mp, offp, proto)
if (proto == IPPROTO_NONE)
m_freem(m);
else {
char *prvnxtp = ip6_get_prevhdr(m, *offp); /* XXX */
u_int8_t *prvnxtp = ip6_get_prevhdr(m, *offp); /* XXX */
in6_ifstat_inc(m->m_pkthdr.rcvif, ifs6_in_protounknown);
icmp6_error(m, ICMP6_PARAM_PROB,
ICMP6_PARAMPROB_NEXTHEADER,
prvnxtp - mtod(m, char *));
prvnxtp - mtod(m, u_int8_t *));
}
ip6stat.ip6s_delivered--;
}

View File

@ -1,4 +1,4 @@
/* $NetBSD: keydb.h,v 1.10 2002/06/12 01:47:37 itojun Exp $ */
/* $NetBSD: keydb.h,v 1.11 2002/09/11 02:41:29 itojun Exp $ */
/* $KAME: keydb.h,v 1.14 2000/08/02 17:58:26 sakane Exp $ */
/*
@ -104,7 +104,7 @@ struct secreplay {
u_int wsize; /* window size, i.g. 4 bytes */
u_int32_t seq; /* used by sender */
u_int32_t lastseq; /* used by receiver */
caddr_t bitmap; /* used by receiver */
u_int8_t *bitmap; /* used by receiver */
int overflow; /* overflow flag */
};