From 56d5e0967c9980b42eccf9bacd986d669fd86990 Mon Sep 17 00:00:00 2001 From: Gleb Smirnoff Date: Mon, 6 Apr 2015 09:42:23 +0000 Subject: [PATCH] Stop including if_var.h from userland. Sponsored by: Nginx, Inc. --- contrib/ipfilter/ipsend/44arp.c | 3 --- contrib/ipfilter/ipsend/ip.c | 3 --- contrib/ipfilter/ipsend/resend.c | 3 --- contrib/ipfilter/lib/kmem.c | 3 --- contrib/ipfilter/tools/ipfs.c | 3 --- contrib/ipfilter/tools/ipnat.c | 3 --- contrib/ipfilter/tools/ipnat_y.y | 3 --- contrib/ipfilter/tools/ippool.c | 3 --- contrib/ipfilter/tools/ippool_y.y | 3 --- lib/libc/net/getaddrinfo.c | 1 - lib/libc/net/name6.c | 1 - sbin/ifconfig/af_inet.c | 1 - sbin/ifconfig/af_inet6.c | 1 - sbin/ifconfig/af_nd6.c | 1 - sbin/ifconfig/carp.c | 1 - sbin/ifconfig/ifconfig.c | 1 - sbin/ifconfig/ifvlan.c | 1 - sbin/ifconfig/ifvxlan.c | 1 - tools/tools/ath/athratestats/main.c | 1 - tools/tools/cxgbtool/cxgbtool.c | 1 - tools/tools/iwn/iwnstats/iwn_ioctl.c | 1 - usr.bin/bluetooth/btsockstat/btsockstat.c | 1 - usr.bin/kdump/mkioctls | 1 - usr.bin/netstat/bpf.c | 1 - usr.bin/netstat/if.c | 1 - usr.bin/netstat/inet6.c | 1 - usr.sbin/amd/include/config.h | 3 --- usr.sbin/ancontrol/ancontrol.c | 1 - usr.sbin/ifmcstat/ifmcstat.c | 1 - usr.sbin/ip6addrctl/ip6addrctl.c | 1 - usr.sbin/mld6query/mld6.c | 1 - usr.sbin/ndp/ndp.c | 1 - usr.sbin/ntp/config.h | 3 --- usr.sbin/ppp/iface.c | 3 --- usr.sbin/rip6query/rip6query.c | 3 --- usr.sbin/route6d/route6d.c | 1 - usr.sbin/rrenumd/lexer.l | 4 ---- usr.sbin/rrenumd/parser.y | 3 --- usr.sbin/rtadvctl/rtadvctl.c | 1 - usr.sbin/rtadvd/config.c | 1 - usr.sbin/rtadvd/if.c | 1 - usr.sbin/rtadvd/rrenum.c | 1 - usr.sbin/rtadvd/rtadvd.c | 1 - usr.sbin/rtsold/if.c | 1 - usr.sbin/rtsold/probe.c | 1 - usr.sbin/rtsold/rtsold.c | 1 - usr.sbin/uhsoctl/uhsoctl.c | 1 - usr.sbin/wpa/ndis_events/ndis_events.c | 1 - usr.sbin/wpa/wpa_supplicant/Packet32.c | 1 - 49 files changed, 80 deletions(-) diff --git a/contrib/ipfilter/ipsend/44arp.c b/contrib/ipfilter/ipsend/44arp.c index 9033ab9a64ba..9215959395ab 100644 --- a/contrib/ipfilter/ipsend/44arp.c +++ b/contrib/ipfilter/ipsend/44arp.c @@ -8,9 +8,6 @@ #include #include #include -#if __FreeBSD_version >= 300000 -# include -#endif #include #include #ifndef __osf__ diff --git a/contrib/ipfilter/ipsend/ip.c b/contrib/ipfilter/ipsend/ip.c index 74d164b6ee85..fc7617065ac7 100644 --- a/contrib/ipfilter/ipsend/ip.c +++ b/contrib/ipfilter/ipsend/ip.c @@ -21,9 +21,6 @@ static const char rcsid[] = "@(#)$Id$"; # include # include # include -# if __FreeBSD_version >= 300000 -# include -# endif #endif #include #include diff --git a/contrib/ipfilter/ipsend/resend.c b/contrib/ipfilter/ipsend/resend.c index d113af38857e..45159bf76455 100644 --- a/contrib/ipfilter/ipsend/resend.c +++ b/contrib/ipfilter/ipsend/resend.c @@ -22,9 +22,6 @@ static const char rcsid[] = "@(#)$Id$"; #ifndef linux # include # include -# if __FreeBSD_version >= 300000 -# include -# endif #endif #include #include diff --git a/contrib/ipfilter/lib/kmem.c b/contrib/ipfilter/lib/kmem.c index 382a51c88c18..d895bafd0540 100644 --- a/contrib/ipfilter/lib/kmem.c +++ b/contrib/ipfilter/lib/kmem.c @@ -29,9 +29,6 @@ #include #include #include -#if __FreeBSD_version >= 300000 -# include -#endif #if defined(linux) || defined(__osf__) || defined(__sgi) || defined(__hpux) # include #endif diff --git a/contrib/ipfilter/tools/ipfs.c b/contrib/ipfilter/tools/ipfs.c index b5484be2193c..43abd748f59f 100644 --- a/contrib/ipfilter/tools/ipfs.c +++ b/contrib/ipfilter/tools/ipfs.c @@ -33,9 +33,6 @@ #include #include #include -#if __FreeBSD_version >= 300000 -# include -#endif #include #include #include diff --git a/contrib/ipfilter/tools/ipnat.c b/contrib/ipfilter/tools/ipnat.c index 448c1c0d2d2a..c3a715698036 100644 --- a/contrib/ipfilter/tools/ipnat.c +++ b/contrib/ipfilter/tools/ipnat.c @@ -37,9 +37,6 @@ #include #include #include -#if __FreeBSD_version >= 300000 -# include -#endif #include #include #include diff --git a/contrib/ipfilter/tools/ipnat_y.y b/contrib/ipfilter/tools/ipnat_y.y index 8c23403b3e03..39e6a92bdf67 100644 --- a/contrib/ipfilter/tools/ipnat_y.y +++ b/contrib/ipfilter/tools/ipnat_y.y @@ -35,9 +35,6 @@ #include #include #include -#if __FreeBSD_version >= 300000 -# include -#endif #include #include #include diff --git a/contrib/ipfilter/tools/ippool.c b/contrib/ipfilter/tools/ippool.c index 49cf7dae63d7..243932c8cc34 100644 --- a/contrib/ipfilter/tools/ippool.c +++ b/contrib/ipfilter/tools/ippool.c @@ -15,9 +15,6 @@ #include #include -#if __FreeBSD_version >= 300000 -# include -#endif #include #include diff --git a/contrib/ipfilter/tools/ippool_y.y b/contrib/ipfilter/tools/ippool_y.y index 34987452c65b..93593ce82eca 100644 --- a/contrib/ipfilter/tools/ippool_y.y +++ b/contrib/ipfilter/tools/ippool_y.y @@ -16,9 +16,6 @@ #include #include -#if __FreeBSD_version >= 300000 -# include -#endif #include #include diff --git a/lib/libc/net/getaddrinfo.c b/lib/libc/net/getaddrinfo.c index c50374e7287a..17c9b651c375 100644 --- a/lib/libc/net/getaddrinfo.c +++ b/lib/libc/net/getaddrinfo.c @@ -64,7 +64,6 @@ __FBSDID("$FreeBSD$"); #include #include #ifdef INET6 -#include #include #include #include diff --git a/lib/libc/net/name6.c b/lib/libc/net/name6.c index 97880a25e7d8..89effe69a354 100644 --- a/lib/libc/net/name6.c +++ b/lib/libc/net/name6.c @@ -94,7 +94,6 @@ __FBSDID("$FreeBSD$"); #include #ifdef INET6 #include -#include #include #include #include /* XXX */ diff --git a/sbin/ifconfig/af_inet.c b/sbin/ifconfig/af_inet.c index c73337374be4..3c3a75742e10 100644 --- a/sbin/ifconfig/af_inet.c +++ b/sbin/ifconfig/af_inet.c @@ -46,7 +46,6 @@ static const char rcsid[] = #include #include -#include /* for struct ifaddr */ #include #include #include diff --git a/sbin/ifconfig/af_inet6.c b/sbin/ifconfig/af_inet6.c index bff66e0d1215..8a18401e7e79 100644 --- a/sbin/ifconfig/af_inet6.c +++ b/sbin/ifconfig/af_inet6.c @@ -48,7 +48,6 @@ static const char rcsid[] = #include #include -#include /* for struct ifaddr */ #include #include #include diff --git a/sbin/ifconfig/af_nd6.c b/sbin/ifconfig/af_nd6.c index 3a510a5576de..9a1be79710a2 100644 --- a/sbin/ifconfig/af_nd6.c +++ b/sbin/ifconfig/af_nd6.c @@ -46,7 +46,6 @@ static const char rcsid[] = #include #include -#include #include #include #include diff --git a/sbin/ifconfig/carp.c b/sbin/ifconfig/carp.c index 2c58fcb1e931..adff153a42ae 100644 --- a/sbin/ifconfig/carp.c +++ b/sbin/ifconfig/carp.c @@ -36,7 +36,6 @@ #include #include -#include #include #include #include diff --git a/sbin/ifconfig/ifconfig.c b/sbin/ifconfig/ifconfig.c index 9d38a27f5ec0..4a7999232be0 100644 --- a/sbin/ifconfig/ifconfig.c +++ b/sbin/ifconfig/ifconfig.c @@ -51,7 +51,6 @@ static const char rcsid[] = #include #include -#include #include #include #include diff --git a/sbin/ifconfig/ifvlan.c b/sbin/ifconfig/ifvlan.c index cefcbbceffb4..1a3fbaa5de47 100644 --- a/sbin/ifconfig/ifvlan.c +++ b/sbin/ifconfig/ifvlan.c @@ -40,7 +40,6 @@ #include #include -#include #include #include diff --git a/sbin/ifconfig/ifvxlan.c b/sbin/ifconfig/ifvxlan.c index 9aa84a29ff2b..48f5331bf686 100644 --- a/sbin/ifconfig/ifvxlan.c +++ b/sbin/ifconfig/ifvxlan.c @@ -39,7 +39,6 @@ __FBSDID("$FreeBSD$"); #include #include -#include #include #include #include diff --git a/tools/tools/ath/athratestats/main.c b/tools/tools/ath/athratestats/main.c index 815ed91bd61e..3881e8543be0 100644 --- a/tools/tools/ath/athratestats/main.c +++ b/tools/tools/ath/athratestats/main.c @@ -38,7 +38,6 @@ #include #include #include -#include #include #include diff --git a/tools/tools/cxgbtool/cxgbtool.c b/tools/tools/cxgbtool/cxgbtool.c index f73f1a4d5c47..8eaaf28e34bd 100644 --- a/tools/tools/cxgbtool/cxgbtool.c +++ b/tools/tools/cxgbtool/cxgbtool.c @@ -52,7 +52,6 @@ __FBSDID("$FreeBSD$"); #include #include -#include #include #include diff --git a/tools/tools/iwn/iwnstats/iwn_ioctl.c b/tools/tools/iwn/iwnstats/iwn_ioctl.c index 13c615397a0c..97b2a918d9ec 100644 --- a/tools/tools/iwn/iwnstats/iwn_ioctl.c +++ b/tools/tools/iwn/iwnstats/iwn_ioctl.c @@ -38,7 +38,6 @@ #include #include #include -#include #include #include diff --git a/usr.bin/bluetooth/btsockstat/btsockstat.c b/usr.bin/bluetooth/btsockstat/btsockstat.c index 20f4de8076c8..a9c93542cfb8 100644 --- a/usr.bin/bluetooth/btsockstat/btsockstat.c +++ b/usr.bin/bluetooth/btsockstat/btsockstat.c @@ -38,7 +38,6 @@ #include #include -#include #include #include diff --git a/usr.bin/kdump/mkioctls b/usr.bin/kdump/mkioctls index a9ba860682af..525e143aa442 100644 --- a/usr.bin/kdump/mkioctls +++ b/usr.bin/kdump/mkioctls @@ -54,7 +54,6 @@ BEGIN { print "#include " print "#include " print "#include " - print "#include " print "#ifdef PF" print "#include " print "#include " diff --git a/usr.bin/netstat/bpf.c b/usr.bin/netstat/bpf.c index b48f9a103b1a..60546e38be14 100644 --- a/usr.bin/netstat/bpf.c +++ b/usr.bin/netstat/bpf.c @@ -36,7 +36,6 @@ __FBSDID("$FreeBSD$"); #include #include -#include #include #include #include diff --git a/usr.bin/netstat/if.c b/usr.bin/netstat/if.c index cc8405e602b9..f04c5310dd86 100644 --- a/usr.bin/netstat/if.c +++ b/usr.bin/netstat/if.c @@ -45,7 +45,6 @@ __FBSDID("$FreeBSD$"); #include #include -#include #include #include #include diff --git a/usr.bin/netstat/inet6.c b/usr.bin/netstat/inet6.c index 0d2006afe28b..3535f4533ae5 100644 --- a/usr.bin/netstat/inet6.c +++ b/usr.bin/netstat/inet6.c @@ -48,7 +48,6 @@ __FBSDID("$FreeBSD$"); #include #include -#include #include #include #include diff --git a/usr.sbin/amd/include/config.h b/usr.sbin/amd/include/config.h index 5817a460a8fb..cffb82ad71f3 100644 --- a/usr.sbin/amd/include/config.h +++ b/usr.sbin/amd/include/config.h @@ -668,9 +668,6 @@ /* Define to 1 if you have the header file. */ #define HAVE_NET_IF_H 1 -/* Define to 1 if you have the header file. */ -#define HAVE_NET_IF_VAR_H 1 - /* Define to 1 if you have the header file. */ #define HAVE_NET_ROUTE_H 1 diff --git a/usr.sbin/ancontrol/ancontrol.c b/usr.sbin/ancontrol/ancontrol.c index 839cdcb311ea..4ff32ff19098 100644 --- a/usr.sbin/ancontrol/ancontrol.c +++ b/usr.sbin/ancontrol/ancontrol.c @@ -46,7 +46,6 @@ __FBSDID("$FreeBSD$"); #include #include -#include #include #include diff --git a/usr.sbin/ifmcstat/ifmcstat.c b/usr.sbin/ifmcstat/ifmcstat.c index d3798e39fab9..4f3f444c276d 100644 --- a/usr.sbin/ifmcstat/ifmcstat.c +++ b/usr.sbin/ifmcstat/ifmcstat.c @@ -41,7 +41,6 @@ __FBSDID("$FreeBSD$"); #include #include -#include #include #include #include diff --git a/usr.sbin/ip6addrctl/ip6addrctl.c b/usr.sbin/ip6addrctl/ip6addrctl.c index 6a730ff1fc30..d9bf89de68b7 100644 --- a/usr.sbin/ip6addrctl/ip6addrctl.c +++ b/usr.sbin/ip6addrctl/ip6addrctl.c @@ -39,7 +39,6 @@ #include #include -#include #include #include diff --git a/usr.sbin/mld6query/mld6.c b/usr.sbin/mld6query/mld6.c index 53f38aea5606..a3c8342e5f50 100644 --- a/usr.sbin/mld6query/mld6.c +++ b/usr.sbin/mld6query/mld6.c @@ -42,7 +42,6 @@ __FBSDID("$FreeBSD$"); #include #include -#include #include #include diff --git a/usr.sbin/ndp/ndp.c b/usr.sbin/ndp/ndp.c index e8960102de25..339a4b61c55f 100644 --- a/usr.sbin/ndp/ndp.c +++ b/usr.sbin/ndp/ndp.c @@ -83,7 +83,6 @@ #include #include -#include #include #include #include diff --git a/usr.sbin/ntp/config.h b/usr.sbin/ntp/config.h index 6c49557d5d92..b771834c1841 100644 --- a/usr.sbin/ntp/config.h +++ b/usr.sbin/ntp/config.h @@ -613,9 +613,6 @@ /* Define to 1 if you have the header file. */ #define HAVE_NET_IF_H 1 -/* Define to 1 if you have the header file. */ -#define HAVE_NET_IF_VAR_H 1 - /* Define to 1 if you have the header file. */ #define HAVE_NET_ROUTE_H 1 diff --git a/usr.sbin/ppp/iface.c b/usr.sbin/ppp/iface.c index 8fee189a9907..5f17769ffa6f 100644 --- a/usr.sbin/ppp/iface.c +++ b/usr.sbin/ppp/iface.c @@ -31,9 +31,6 @@ #include #include #include -#ifdef __FreeBSD__ -#include -#endif #include #include #include diff --git a/usr.sbin/rip6query/rip6query.c b/usr.sbin/rip6query/rip6query.c index ea448ba227c0..a35c75097415 100644 --- a/usr.sbin/rip6query/rip6query.c +++ b/usr.sbin/rip6query/rip6query.c @@ -46,9 +46,6 @@ #include #include -#if defined(__FreeBSD__) && __FreeBSD__ >= 3 -#include -#endif /* __FreeBSD__ >= 3 */ #include #include #include diff --git a/usr.sbin/route6d/route6d.c b/usr.sbin/route6d/route6d.c index 258219bafa02..3c3d9d30f8c5 100644 --- a/usr.sbin/route6d/route6d.c +++ b/usr.sbin/route6d/route6d.c @@ -63,7 +63,6 @@ static const char _rcsid[] = "$KAME: route6d.c,v 1.104 2003/10/31 00:30:20 itoju #include #include #include -#include #include #include #include diff --git a/usr.sbin/rrenumd/lexer.l b/usr.sbin/rrenumd/lexer.l index 6e55f9e88f06..47656e86d2b1 100644 --- a/usr.sbin/rrenumd/lexer.l +++ b/usr.sbin/rrenumd/lexer.l @@ -40,10 +40,6 @@ #include #include -#if defined(__FreeBSD__) && __FreeBSD__ >= 3 -#include -#endif /* __FreeBSD__ >= 3 */ - #include #include #include diff --git a/usr.sbin/rrenumd/parser.y b/usr.sbin/rrenumd/parser.y index 65dfd466c9f6..6436df709b2e 100644 --- a/usr.sbin/rrenumd/parser.y +++ b/usr.sbin/rrenumd/parser.y @@ -39,9 +39,6 @@ #include #include -#if defined(__FreeBSD__) && __FreeBSD__ >= 3 -#include -#endif /* __FreeBSD__ >= 3 */ #include #include diff --git a/usr.sbin/rtadvctl/rtadvctl.c b/usr.sbin/rtadvctl/rtadvctl.c index 3f225187129a..f1657d799cb7 100644 --- a/usr.sbin/rtadvctl/rtadvctl.c +++ b/usr.sbin/rtadvctl/rtadvctl.c @@ -36,7 +36,6 @@ #include #include #include -#include #include #include #include diff --git a/usr.sbin/rtadvd/config.c b/usr.sbin/rtadvd/config.c index 5c9d778e961f..4f14e0fbe82b 100644 --- a/usr.sbin/rtadvd/config.c +++ b/usr.sbin/rtadvd/config.c @@ -36,7 +36,6 @@ #include #include -#include #include #include diff --git a/usr.sbin/rtadvd/if.c b/usr.sbin/rtadvd/if.c index 5413cdf4b80c..0eef73436171 100644 --- a/usr.sbin/rtadvd/if.c +++ b/usr.sbin/rtadvd/if.c @@ -38,7 +38,6 @@ #include #include #include -#include #include #include #include diff --git a/usr.sbin/rtadvd/rrenum.c b/usr.sbin/rtadvd/rrenum.c index 0c97d98cdc44..eede4b6d00aa 100644 --- a/usr.sbin/rtadvd/rrenum.c +++ b/usr.sbin/rtadvd/rrenum.c @@ -37,7 +37,6 @@ #include #include -#include #include #include #include diff --git a/usr.sbin/rtadvd/rtadvd.c b/usr.sbin/rtadvd/rtadvd.c index 6554b61495a4..0169a5657a1b 100644 --- a/usr.sbin/rtadvd/rtadvd.c +++ b/usr.sbin/rtadvd/rtadvd.c @@ -51,7 +51,6 @@ #include -#include #include #include diff --git a/usr.sbin/rtsold/if.c b/usr.sbin/rtsold/if.c index 2bf946daf2a7..6274d0f58c90 100644 --- a/usr.sbin/rtsold/if.c +++ b/usr.sbin/rtsold/if.c @@ -38,7 +38,6 @@ #include #include -#include #include #include #include diff --git a/usr.sbin/rtsold/probe.c b/usr.sbin/rtsold/probe.c index 5ec54aae5d02..89a1617a75df 100644 --- a/usr.sbin/rtsold/probe.c +++ b/usr.sbin/rtsold/probe.c @@ -40,7 +40,6 @@ #include #include -#include #include #include diff --git a/usr.sbin/rtsold/rtsold.c b/usr.sbin/rtsold/rtsold.c index a97b884cc583..bba15bb88b04 100644 --- a/usr.sbin/rtsold/rtsold.c +++ b/usr.sbin/rtsold/rtsold.c @@ -38,7 +38,6 @@ #include #include -#include #include #include diff --git a/usr.sbin/uhsoctl/uhsoctl.c b/usr.sbin/uhsoctl/uhsoctl.c index 21b62209aaad..686d45ffd179 100644 --- a/usr.sbin/uhsoctl/uhsoctl.c +++ b/usr.sbin/uhsoctl/uhsoctl.c @@ -37,7 +37,6 @@ #include #include -#include #include #include #include diff --git a/usr.sbin/wpa/ndis_events/ndis_events.c b/usr.sbin/wpa/ndis_events/ndis_events.c index 9c6e9def54a9..b61fd0a297ab 100644 --- a/usr.sbin/wpa/ndis_events/ndis_events.c +++ b/usr.sbin/wpa/ndis_events/ndis_events.c @@ -49,7 +49,6 @@ __FBSDID("$FreeBSD$"); #include #include #include -#include #include #include diff --git a/usr.sbin/wpa/wpa_supplicant/Packet32.c b/usr.sbin/wpa/wpa_supplicant/Packet32.c index 876417e6635a..8e7da035af95 100644 --- a/usr.sbin/wpa/wpa_supplicant/Packet32.c +++ b/usr.sbin/wpa/wpa_supplicant/Packet32.c @@ -49,7 +49,6 @@ __FBSDID("$FreeBSD$"); #include #include #include -#include #include #include