Wrap the new world order in __FreeBSD__ to ease future imports.
This commit is contained in:
parent
fff86fc443
commit
ef2e5f06f2
@ -271,10 +271,17 @@ pflogioctl(struct ifnet *ifp, u_long cmd, caddr_t data)
|
|||||||
case SIOCAIFADDR:
|
case SIOCAIFADDR:
|
||||||
case SIOCSIFDSTADDR:
|
case SIOCSIFDSTADDR:
|
||||||
case SIOCSIFFLAGS:
|
case SIOCSIFFLAGS:
|
||||||
|
#ifdef __FreeBSD__
|
||||||
if (ifp->if_flags & IFF_UP)
|
if (ifp->if_flags & IFF_UP)
|
||||||
ifp->if_drv_flags |= IFF_DRV_RUNNING;
|
ifp->if_drv_flags |= IFF_DRV_RUNNING;
|
||||||
else
|
else
|
||||||
ifp->if_drv_flags &= ~IFF_DRV_RUNNING;
|
ifp->if_drv_flags &= ~IFF_DRV_RUNNING;
|
||||||
|
#else
|
||||||
|
if (ifp->if_flags & IFF_UP)
|
||||||
|
ifp->if_flags |= IFF_RUNNING;
|
||||||
|
else
|
||||||
|
ifp->if_flags &= ~IFF_RUNNING;
|
||||||
|
#endif
|
||||||
break;
|
break;
|
||||||
default:
|
default:
|
||||||
return (EINVAL);
|
return (EINVAL);
|
||||||
|
@ -989,10 +989,17 @@ pfsyncioctl(struct ifnet *ifp, u_long cmd, caddr_t data)
|
|||||||
case SIOCAIFADDR:
|
case SIOCAIFADDR:
|
||||||
case SIOCSIFDSTADDR:
|
case SIOCSIFDSTADDR:
|
||||||
case SIOCSIFFLAGS:
|
case SIOCSIFFLAGS:
|
||||||
|
#ifdef __FreeBSD__
|
||||||
if (ifp->if_flags & IFF_UP)
|
if (ifp->if_flags & IFF_UP)
|
||||||
ifp->if_drv_flags |= IFF_DRV_RUNNING;
|
ifp->if_drv_flags |= IFF_DRV_RUNNING;
|
||||||
else
|
else
|
||||||
ifp->if_drv_flags &= ~IFF_DRV_RUNNING;
|
ifp->if_drv_flags &= ~IFF_DRV_RUNNING;
|
||||||
|
#else
|
||||||
|
if (ifp->if_flags & IFF_UP)
|
||||||
|
ifp->if_flags |= IFF_RUNNING;
|
||||||
|
else
|
||||||
|
ifp->if_flags &= ~IFF_RUNNING;
|
||||||
|
#endif
|
||||||
break;
|
break;
|
||||||
case SIOCSIFMTU:
|
case SIOCSIFMTU:
|
||||||
if (ifr->ifr_mtu < PFSYNC_MINMTU)
|
if (ifr->ifr_mtu < PFSYNC_MINMTU)
|
||||||
|
Loading…
x
Reference in New Issue
Block a user