remove unnecessary casts (no functional change)
This commit is contained in:
parent
2b50acc97b
commit
da38d88a6c
|
@ -1,4 +1,4 @@
|
|||
/* $NetBSD: ip_input.c,v 1.356 2017/07/06 17:08:57 christos Exp $ */
|
||||
/* $NetBSD: ip_input.c,v 1.357 2017/07/06 17:12:34 christos Exp $ */
|
||||
|
||||
/*
|
||||
* Copyright (C) 1995, 1996, 1997, and 1998 WIDE Project.
|
||||
|
@ -91,7 +91,7 @@
|
|||
*/
|
||||
|
||||
#include <sys/cdefs.h>
|
||||
__KERNEL_RCSID(0, "$NetBSD: ip_input.c,v 1.356 2017/07/06 17:08:57 christos Exp $");
|
||||
__KERNEL_RCSID(0, "$NetBSD: ip_input.c,v 1.357 2017/07/06 17:12:34 christos Exp $");
|
||||
|
||||
#ifdef _KERNEL_OPT
|
||||
#include "opt_inet.h"
|
||||
|
@ -1527,7 +1527,7 @@ ip_savecontrol(struct inpcb *inp, struct mbuf **mp, struct ip *ip,
|
|||
mp = sbsavetimestamp(so->so_options, m, mp);
|
||||
|
||||
if (inpflags & INP_RECVDSTADDR) {
|
||||
*mp = sbcreatecontrol((void *) &ip->ip_dst,
|
||||
*mp = sbcreatecontrol(&ip->ip_dst,
|
||||
sizeof(struct in_addr), IP_RECVDSTADDR, IPPROTO_IP);
|
||||
if (*mp)
|
||||
mp = &(*mp)->m_next;
|
||||
|
@ -1536,7 +1536,7 @@ ip_savecontrol(struct inpcb *inp, struct mbuf **mp, struct ip *ip,
|
|||
struct in_pktinfo ipi;
|
||||
ipi.ipi_addr = ip->ip_src;
|
||||
ipi.ipi_ifindex = ifp->if_index;
|
||||
*mp = sbcreatecontrol((void *) &ipi,
|
||||
*mp = sbcreatecontrol(&ipi,
|
||||
sizeof(ipi), IP_RECVPKTINFO, IPPROTO_IP);
|
||||
if (*mp)
|
||||
mp = &(*mp)->m_next;
|
||||
|
@ -1545,7 +1545,7 @@ ip_savecontrol(struct inpcb *inp, struct mbuf **mp, struct ip *ip,
|
|||
struct in_pktinfo ipi;
|
||||
ipi.ipi_addr = ip->ip_dst;
|
||||
ipi.ipi_ifindex = ifp->if_index;
|
||||
*mp = sbcreatecontrol((void *) &ipi,
|
||||
*mp = sbcreatecontrol(&ipi,
|
||||
sizeof(ipi), IP_PKTINFO, IPPROTO_IP);
|
||||
if (*mp)
|
||||
mp = &(*mp)->m_next;
|
||||
|
@ -1560,7 +1560,7 @@ ip_savecontrol(struct inpcb *inp, struct mbuf **mp, struct ip *ip,
|
|||
mp = &(*mp)->m_next;
|
||||
}
|
||||
if (inpflags & INP_RECVTTL) {
|
||||
*mp = sbcreatecontrol((void *) &ip->ip_ttl,
|
||||
*mp = sbcreatecontrol(&ip->ip_ttl,
|
||||
sizeof(uint8_t), IP_RECVTTL, IPPROTO_IP);
|
||||
if (*mp)
|
||||
mp = &(*mp)->m_next;
|
||||
|
|
Loading…
Reference in New Issue