diff options
author | ume <ume@FreeBSD.org> | 2003-10-29 12:52:28 +0000 |
---|---|---|
committer | ume <ume@FreeBSD.org> | 2003-10-29 12:52:28 +0000 |
commit | 36edae8e0d6caa4c38b5624886e0b8a21fc77870 (patch) | |
tree | 625e8695c0868711307e6da1669ffa5509bdbfcf /sys | |
parent | bde54b9152c6e052b2d02175676d7eeac29baa99 (diff) | |
download | FreeBSD-src-36edae8e0d6caa4c38b5624886e0b8a21fc77870.zip FreeBSD-src-36edae8e0d6caa4c38b5624886e0b8a21fc77870.tar.gz |
ip6_savecontrol() argument is redundant
Diffstat (limited to 'sys')
-rw-r--r-- | sys/netinet/udp_usrreq.c | 2 | ||||
-rw-r--r-- | sys/netinet6/icmp6.c | 4 | ||||
-rw-r--r-- | sys/netinet6/ip6_input.c | 7 | ||||
-rw-r--r-- | sys/netinet6/ip6_var.h | 3 | ||||
-rw-r--r-- | sys/netinet6/raw_ip6.c | 4 | ||||
-rw-r--r-- | sys/netinet6/udp6_usrreq.c | 7 |
6 files changed, 12 insertions, 15 deletions
diff --git a/sys/netinet/udp_usrreq.c b/sys/netinet/udp_usrreq.c index 8cecb7b..8950234 100644 --- a/sys/netinet/udp_usrreq.c +++ b/sys/netinet/udp_usrreq.c @@ -458,7 +458,7 @@ udp_append(last, ip, n, off) } savedflags = last->inp_flags; last->inp_flags &= ~INP_UNMAPPABLEOPTS; - ip6_savecontrol(last, &opts, &udp_ip6.uip6_ip6, n); + ip6_savecontrol(last, n, &opts); last->inp_flags = savedflags; } else #endif diff --git a/sys/netinet6/icmp6.c b/sys/netinet6/icmp6.c index 91ae896..272e046 100644 --- a/sys/netinet6/icmp6.c +++ b/sys/netinet6/icmp6.c @@ -1944,7 +1944,7 @@ icmp6_rip6_input(mp, off) struct mbuf *n; if ((n = m_copy(m, 0, (int)M_COPYALL)) != NULL) { if (last->in6p_flags & IN6P_CONTROLOPTS) - ip6_savecontrol(last, &opts, ip6, n); + ip6_savecontrol(last, n, &opts); /* strip intermediate headers */ m_adj(n, off); if (sbappendaddr(&last->in6p_socket->so_rcv, @@ -1964,7 +1964,7 @@ icmp6_rip6_input(mp, off) } if (last) { if (last->in6p_flags & IN6P_CONTROLOPTS) - ip6_savecontrol(last, &opts, ip6, m); + ip6_savecontrol(last, m, &opts); /* strip intermediate headers */ m_adj(m, off); if (sbappendaddr(&last->in6p_socket->so_rcv, diff --git a/sys/netinet6/ip6_input.c b/sys/netinet6/ip6_input.c index 10b9823..adc9e87 100644 --- a/sys/netinet6/ip6_input.c +++ b/sys/netinet6/ip6_input.c @@ -1055,15 +1055,14 @@ ip6_unknown_opt(optp, m, off) * very first mbuf on the mbuf chain. */ void -ip6_savecontrol(in6p, mp, ip6, m) +ip6_savecontrol(in6p, m, mp) struct inpcb *in6p; - struct mbuf **mp; - struct ip6_hdr *ip6; - struct mbuf *m; + struct mbuf *m, **mp; { #define IS2292(x, y) ((in6p->in6p_flags & IN6P_RFC2292) ? (x) : (y)) struct thread *td = curthread; /* XXX */ int privileged = 0; + struct ip6_hdr *ip6 = mtod(m, struct ip6_hdr *); if (td && !suser(td)) privileged++; diff --git a/sys/netinet6/ip6_var.h b/sys/netinet6/ip6_var.h index 6edaa1c..fecb610 100644 --- a/sys/netinet6/ip6_var.h +++ b/sys/netinet6/ip6_var.h @@ -352,8 +352,7 @@ void ip6_delaux __P((struct mbuf *)); int ip6_mforward __P((struct ip6_hdr *, struct ifnet *, struct mbuf *)); int ip6_process_hopopts __P((struct mbuf *, u_int8_t *, int, u_int32_t *, u_int32_t *)); -void ip6_savecontrol __P((struct inpcb *, struct mbuf **, struct ip6_hdr *, - struct mbuf *)); +void ip6_savecontrol __P((struct inpcb *, struct mbuf *, struct mbuf **)); void ip6_notify_pmtu __P((struct inpcb *, struct sockaddr_in6 *, u_int32_t *)); int ip6_sysctl __P((int *, u_int, void *, size_t *, void *, size_t)); diff --git a/sys/netinet6/raw_ip6.c b/sys/netinet6/raw_ip6.c index 6dddaac..4f77fae 100644 --- a/sys/netinet6/raw_ip6.c +++ b/sys/netinet6/raw_ip6.c @@ -198,7 +198,7 @@ rip6_input(mp, offp, proto) if (n) { if (last->in6p_flags & IN6P_CONTROLOPTS || last->in6p_socket->so_options & SO_TIMESTAMP) - ip6_savecontrol(last, &opts, ip6, n); + ip6_savecontrol(last, n, &opts); /* strip intermediate headers */ m_adj(n, *offp); if (sbappendaddr(&last->in6p_socket->so_rcv, @@ -239,7 +239,7 @@ rip6_input(mp, offp, proto) if (last) { if (last->in6p_flags & IN6P_CONTROLOPTS || last->in6p_socket->so_options & SO_TIMESTAMP) - ip6_savecontrol(last, &opts, ip6, m); + ip6_savecontrol(last, m, &opts); /* strip intermediate headers */ m_adj(m, *offp); if (sbappendaddr(&last->in6p_socket->so_rcv, diff --git a/sys/netinet6/udp6_usrreq.c b/sys/netinet6/udp6_usrreq.c index 8a78fb4..0e5fa97 100644 --- a/sys/netinet6/udp6_usrreq.c +++ b/sys/netinet6/udp6_usrreq.c @@ -284,8 +284,7 @@ udp6_input(mp, offp, proto) */ if (last->in6p_flags & IN6P_CONTROLOPTS || last->in6p_socket->so_options & SO_TIMESTAMP) - ip6_savecontrol(last, &opts, - ip6, n); + ip6_savecontrol(last, n, &opts); m_adj(n, off + sizeof(struct udphdr)); if (sbappendaddr(&last->in6p_socket->so_rcv, @@ -343,7 +342,7 @@ udp6_input(mp, offp, proto) #endif /* FAST_IPSEC */ if (last->in6p_flags & IN6P_CONTROLOPTS || last->in6p_socket->so_options & SO_TIMESTAMP) - ip6_savecontrol(last, &opts, ip6, m); + ip6_savecontrol(last, m, &opts); m_adj(m, off + sizeof(struct udphdr)); if (sbappendaddr(&last->in6p_socket->so_rcv, @@ -406,7 +405,7 @@ udp6_input(mp, offp, proto) udp_in6.sin6_port = uh->uh_sport; if (in6p->in6p_flags & IN6P_CONTROLOPTS || in6p->in6p_socket->so_options & SO_TIMESTAMP) - ip6_savecontrol(in6p, &opts, ip6, m); + ip6_savecontrol(in6p, m, &opts); m_adj(m, off + sizeof(struct udphdr)); if (sbappendaddr(&in6p->in6p_socket->so_rcv, (struct sockaddr *)&udp_in6, |