summaryrefslogtreecommitdiff
path: root/usr.bin
diff options
context:
space:
mode:
Diffstat (limited to 'usr.bin')
-rw-r--r--usr.bin/netstat/if.c6
-rw-r--r--usr.bin/netstat/inet.c30
-rw-r--r--usr.bin/netstat/inet6.c12
-rw-r--r--usr.bin/netstat/main.c4
-rw-r--r--usr.bin/netstat/mroute.c8
-rw-r--r--usr.bin/netstat/mroute6.c8
-rw-r--r--usr.bin/systat/if.c4
7 files changed, 36 insertions, 36 deletions
diff --git a/usr.bin/netstat/if.c b/usr.bin/netstat/if.c
index 13acb68b99b..f722db23e89 100644
--- a/usr.bin/netstat/if.c
+++ b/usr.bin/netstat/if.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: if.c,v 1.67 2013/11/21 17:32:13 mikeb Exp $ */
+/* $OpenBSD: if.c,v 1.68 2014/06/23 03:46:17 guenther Exp $ */
/* $NetBSD: if.c,v 1.16.4.2 1996/06/07 21:46:46 thorpej Exp $ */
/*
@@ -73,7 +73,7 @@ void
intpr(int interval, int repeatcount)
{
struct if_msghdr ifm;
- int mib[6] = { CTL_NET, AF_ROUTE, 0, 0, NET_RT_IFLIST, 0 };
+ int mib[6] = { CTL_NET, PF_ROUTE, 0, 0, NET_RT_IFLIST, 0 };
char name[IFNAMSIZ + 1]; /* + 1 for the '*' */
char *buf, *next, *lim, *cp;
struct rt_msghdr *rtm;
@@ -552,7 +552,7 @@ static void
fetchifs(void)
{
struct if_msghdr ifm;
- int mib[6] = { CTL_NET, AF_ROUTE, 0, 0, NET_RT_IFLIST, 0 };
+ int mib[6] = { CTL_NET, PF_ROUTE, 0, 0, NET_RT_IFLIST, 0 };
struct rt_msghdr *rtm;
struct if_data *ifd;
struct sockaddr *sa, *rti_info[RTAX_MAX];
diff --git a/usr.bin/netstat/inet.c b/usr.bin/netstat/inet.c
index 5ae86ec48a7..a993ad7b240 100644
--- a/usr.bin/netstat/inet.c
+++ b/usr.bin/netstat/inet.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: inet.c,v 1.132 2014/01/25 10:03:32 claudio Exp $ */
+/* $OpenBSD: inet.c,v 1.133 2014/06/23 03:46:17 guenther Exp $ */
/* $NetBSD: inet.c,v 1.14 1995/10/03 21:42:37 thorpej Exp $ */
/*
@@ -254,7 +254,7 @@ void
tcp_stats(char *name)
{
struct tcpstat tcpstat;
- int mib[] = { CTL_NET, AF_INET, IPPROTO_TCP, TCPCTL_STATS };
+ int mib[] = { CTL_NET, PF_INET, IPPROTO_TCP, TCPCTL_STATS };
size_t len = sizeof(tcpstat);
if (sysctl(mib, sizeof(mib) / sizeof(mib[0]),
@@ -385,7 +385,7 @@ udp_stats(char *name)
{
struct udpstat udpstat;
u_long delivered;
- int mib[] = { CTL_NET, AF_INET, IPPROTO_UDP, UDPCTL_STATS };
+ int mib[] = { CTL_NET, PF_INET, IPPROTO_UDP, UDPCTL_STATS };
size_t len = sizeof(udpstat);
if (sysctl(mib, sizeof(mib) / sizeof(mib[0]),
@@ -431,7 +431,7 @@ void
ip_stats(char *name)
{
struct ipstat ipstat;
- int mib[] = { CTL_NET, AF_INET, IPPROTO_IP, IPCTL_STATS };
+ int mib[] = { CTL_NET, PF_INET, IPPROTO_IP, IPCTL_STATS };
size_t len = sizeof(ipstat);
if (sysctl(mib, sizeof(mib) / sizeof(mib[0]),
@@ -490,7 +490,7 @@ void
div_stats(char *name)
{
struct divstat divstat;
- int mib[] = { CTL_NET, AF_INET, IPPROTO_DIVERT, DIVERTCTL_STATS };
+ int mib[] = { CTL_NET, PF_INET, IPPROTO_DIVERT, DIVERTCTL_STATS };
size_t len = sizeof(divstat);
if (sysctl(mib, sizeof(mib) / sizeof(mib[0]),
@@ -566,7 +566,7 @@ icmp_stats(char *name)
{
struct icmpstat icmpstat;
int i, first;
- int mib[] = { CTL_NET, AF_INET, IPPROTO_ICMP, ICMPCTL_STATS };
+ int mib[] = { CTL_NET, PF_INET, IPPROTO_ICMP, ICMPCTL_STATS };
size_t len = sizeof(icmpstat);
if (sysctl(mib, sizeof(mib) / sizeof(mib[0]),
@@ -627,7 +627,7 @@ void
igmp_stats(char *name)
{
struct igmpstat igmpstat;
- int mib[] = { CTL_NET, AF_INET, IPPROTO_IGMP, IGMPCTL_STATS };
+ int mib[] = { CTL_NET, PF_INET, IPPROTO_IGMP, IGMPCTL_STATS };
size_t len = sizeof(igmpstat);
if (sysctl(mib, sizeof(mib) / sizeof(mib[0]),
@@ -663,7 +663,7 @@ void
pim_stats(char *name)
{
struct pimstat pimstat;
- int mib[] = { CTL_NET, AF_INET, IPPROTO_PIM, PIMCTL_STATS };
+ int mib[] = { CTL_NET, PF_INET, IPPROTO_PIM, PIMCTL_STATS };
size_t len = sizeof(pimstat);
if (sysctl(mib, sizeof(mib) / sizeof(mib[0]),
@@ -857,7 +857,7 @@ void
ah_stats(char *name)
{
struct ahstat ahstat;
- int mib[] = { CTL_NET, AF_INET, IPPROTO_AH, AHCTL_STATS };
+ int mib[] = { CTL_NET, PF_INET, IPPROTO_AH, AHCTL_STATS };
size_t len = sizeof(ahstat);
if (sysctl(mib, sizeof(mib) / sizeof(mib[0]),
@@ -903,7 +903,7 @@ void
etherip_stats(char *name)
{
struct etheripstat etheripstat;
- int mib[] = { CTL_NET, AF_INET, IPPROTO_ETHERIP, ETHERIPCTL_STATS };
+ int mib[] = { CTL_NET, PF_INET, IPPROTO_ETHERIP, ETHERIPCTL_STATS };
size_t len = sizeof(etheripstat);
if (sysctl(mib, sizeof(mib) / sizeof(mib[0]),
@@ -936,7 +936,7 @@ void
esp_stats(char *name)
{
struct espstat espstat;
- int mib[] = { CTL_NET, AF_INET, IPPROTO_ESP, ESPCTL_STATS };
+ int mib[] = { CTL_NET, PF_INET, IPPROTO_ESP, ESPCTL_STATS };
size_t len = sizeof(espstat);
if (sysctl(mib, sizeof(mib) / sizeof(mib[0]),
@@ -983,7 +983,7 @@ void
ipip_stats(char *name)
{
struct ipipstat ipipstat;
- int mib[] = { CTL_NET, AF_INET, IPPROTO_IPIP, IPIPCTL_STATS };
+ int mib[] = { CTL_NET, PF_INET, IPPROTO_IPIP, IPIPCTL_STATS };
size_t len = sizeof(ipipstat);
if (sysctl(mib, sizeof(mib) / sizeof(mib[0]),
@@ -1017,7 +1017,7 @@ void
carp_stats(char *name)
{
struct carpstats carpstat;
- int mib[] = { CTL_NET, AF_INET, IPPROTO_CARP, CARPCTL_STATS };
+ int mib[] = { CTL_NET, PF_INET, IPPROTO_CARP, CARPCTL_STATS };
size_t len = sizeof(carpstat);
if (sysctl(mib, sizeof(mib) / sizeof(mib[0]),
@@ -1059,7 +1059,7 @@ void
pfsync_stats(char *name)
{
struct pfsyncstats pfsyncstat;
- int mib[] = { CTL_NET, AF_INET, IPPROTO_PFSYNC, PFSYNCCTL_STATS };
+ int mib[] = { CTL_NET, PF_INET, IPPROTO_PFSYNC, PFSYNCCTL_STATS };
size_t len = sizeof(pfsyncstat);
if (sysctl(mib, sizeof(mib) / sizeof(mib[0]),
@@ -1133,7 +1133,7 @@ void
ipcomp_stats(char *name)
{
struct ipcompstat ipcompstat;
- int mib[] = { CTL_NET, AF_INET, IPPROTO_IPCOMP, IPCOMPCTL_STATS };
+ int mib[] = { CTL_NET, PF_INET, IPPROTO_IPCOMP, IPCOMPCTL_STATS };
size_t len = sizeof(ipcompstat);
if (sysctl(mib, sizeof(mib) / sizeof(mib[0]),
diff --git a/usr.bin/netstat/inet6.c b/usr.bin/netstat/inet6.c
index 9dd2fac4629..867a177418d 100644
--- a/usr.bin/netstat/inet6.c
+++ b/usr.bin/netstat/inet6.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: inet6.c,v 1.44 2013/08/18 16:32:24 guenther Exp $ */
+/* $OpenBSD: inet6.c,v 1.45 2014/06/23 03:46:17 guenther Exp $ */
/* BSDI inet.c,v 2.3 1995/10/24 02:19:29 prb Exp */
/*
* Copyright (c) 1983, 1988, 1993
@@ -337,7 +337,7 @@ ip6_stats(char *name)
int first, i;
struct protoent *ep;
const char *n;
- int mib[] = { CTL_NET, AF_INET6, IPPROTO_IPV6, IPV6CTL_STATS };
+ int mib[] = { CTL_NET, PF_INET6, IPPROTO_IPV6, IPV6CTL_STATS };
size_t len = sizeof(ip6stat);
if (sysctl(mib, sizeof(mib) / sizeof(mib[0]),
@@ -816,7 +816,7 @@ icmp6_stats(char *name)
{
struct icmp6stat icmp6stat;
int i, first;
- int mib[] = { CTL_NET, AF_INET6, IPPROTO_ICMPV6, ICMPV6CTL_STATS };
+ int mib[] = { CTL_NET, PF_INET6, IPPROTO_ICMPV6, ICMPV6CTL_STATS };
size_t len = sizeof(icmp6stat);
if (sysctl(mib, sizeof(mib) / sizeof(mib[0]),
@@ -961,7 +961,7 @@ void
pim6_stats(char *name)
{
struct pim6stat pim6stat;
- int mib[] = { CTL_NET, AF_INET6, IPPROTO_PIM, PIM6CTL_STATS };
+ int mib[] = { CTL_NET, PF_INET6, IPPROTO_PIM, PIM6CTL_STATS };
size_t len = sizeof(pim6stat);
if (sysctl(mib, sizeof(mib) / sizeof(mib[0]),
@@ -993,7 +993,7 @@ rip6_stats(char *name)
{
struct rip6stat rip6stat;
u_int64_t delivered;
- int mib[] = { CTL_NET, AF_INET6, IPPROTO_RAW, RIPV6CTL_STATS };
+ int mib[] = { CTL_NET, PF_INET6, IPPROTO_RAW, RIPV6CTL_STATS };
size_t len = sizeof(rip6stat);
if (sysctl(mib, sizeof(mib) / sizeof(mib[0]),
@@ -1033,7 +1033,7 @@ void
div6_stats(char *name)
{
struct div6stat div6stat;
- int mib[] = { CTL_NET, AF_INET6, IPPROTO_DIVERT, DIVERT6CTL_STATS };
+ int mib[] = { CTL_NET, PF_INET6, IPPROTO_DIVERT, DIVERT6CTL_STATS };
size_t len = sizeof(div6stat);
if (sysctl(mib, sizeof(mib) / sizeof(mib[0]),
diff --git a/usr.bin/netstat/main.c b/usr.bin/netstat/main.c
index 765be267585..84c753da3bd 100644
--- a/usr.bin/netstat/main.c
+++ b/usr.bin/netstat/main.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: main.c,v 1.100 2014/02/13 20:51:21 tedu Exp $ */
+/* $OpenBSD: main.c,v 1.101 2014/06/23 03:46:17 guenther Exp $ */
/* $NetBSD: main.c,v 1.9 1996/05/07 02:55:02 thorpej Exp $ */
/*
@@ -563,7 +563,7 @@ gettable(const char *s)
errx(1, "invalid table id: %s", errstr);
mib[0] = CTL_NET;
- mib[1] = AF_ROUTE;
+ mib[1] = PF_ROUTE;
mib[2] = 0;
mib[3] = 0;
mib[4] = NET_RT_TABLE;
diff --git a/usr.bin/netstat/mroute.c b/usr.bin/netstat/mroute.c
index 992c29bc790..cbacaf930ce 100644
--- a/usr.bin/netstat/mroute.c
+++ b/usr.bin/netstat/mroute.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: mroute.c,v 1.20 2013/04/18 15:44:01 deraadt Exp $ */
+/* $OpenBSD: mroute.c,v 1.21 2014/06/23 03:46:17 guenther Exp $ */
/* $NetBSD: mroute.c,v 1.10 1996/05/11 13:51:27 mycroft Exp $ */
/*
@@ -94,7 +94,7 @@ mroutepr(u_long mfchashtbladdr, u_long mfchashaddr, u_long vifaddr)
struct vif viftable[MAXVIFS], *v;
struct mfc *mfcp, mfc;
vifi_t vifi;
- int mib[] = { CTL_NET, AF_INET, IPPROTO_IP, IPCTL_MRTPROTO };
+ int mib[] = { CTL_NET, PF_INET, IPPROTO_IP, IPCTL_MRTPROTO };
size_t len = sizeof(int);
int i, banner_printed = 0, saved_nflag, numvifs = 0;
int nmfc; /* No. of cache entries */
@@ -300,8 +300,8 @@ mrt_stats(void)
{
u_int mrtproto;
struct mrtstat mrtstat;
- int mib[] = { CTL_NET, AF_INET, IPPROTO_IP, IPCTL_MRTPROTO };
- int mib2[] = { CTL_NET, AF_INET, IPPROTO_IP, IPCTL_MRTSTATS };
+ int mib[] = { CTL_NET, PF_INET, IPPROTO_IP, IPCTL_MRTPROTO };
+ int mib2[] = { CTL_NET, PF_INET, IPPROTO_IP, IPCTL_MRTSTATS };
size_t len = sizeof(int);
if (sysctl(mib, sizeof(mib) / sizeof(mib[0]),
diff --git a/usr.bin/netstat/mroute6.c b/usr.bin/netstat/mroute6.c
index 93249e3683e..b198ea4e34b 100644
--- a/usr.bin/netstat/mroute6.c
+++ b/usr.bin/netstat/mroute6.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: mroute6.c,v 1.12 2013/11/21 17:32:13 mikeb Exp $ */
+/* $OpenBSD: mroute6.c,v 1.13 2014/06/23 03:46:17 guenther Exp $ */
/*
* Copyright (C) 1998 WIDE Project.
@@ -98,7 +98,7 @@ mroute6pr(u_long mfcaddr, u_long mifaddr)
mifi_t maxmif = 0, mifi;
struct mf6c mfc;
u_int mrtproto;
- int mib[] = { CTL_NET, AF_INET6, IPPROTO_IPV6, IPV6CTL_MRTPROTO };
+ int mib[] = { CTL_NET, PF_INET6, IPPROTO_IPV6, IPV6CTL_MRTPROTO };
size_t len = sizeof(int);
if (sysctl(mib, sizeof(mib) / sizeof(mib[0]),
@@ -212,8 +212,8 @@ mrt6_stats(void)
{
struct mrt6stat mrt6stat;
u_int mrt6proto;
- int mib[] = { CTL_NET, AF_INET6, IPPROTO_IPV6, IPV6CTL_MRTPROTO };
- int mib2[] = { CTL_NET, AF_INET6, IPPROTO_IPV6, IPV6CTL_MRTSTATS };
+ int mib[] = { CTL_NET, PF_INET6, IPPROTO_IPV6, IPV6CTL_MRTPROTO };
+ int mib2[] = { CTL_NET, PF_INET6, IPPROTO_IPV6, IPV6CTL_MRTSTATS };
size_t len = sizeof(int);
if (sysctl(mib, sizeof(mib) / sizeof(mib[0]),
diff --git a/usr.bin/systat/if.c b/usr.bin/systat/if.c
index 74aedd035af..975a513a4b7 100644
--- a/usr.bin/systat/if.c
+++ b/usr.bin/systat/if.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: if.c,v 1.20 2011/04/05 07:35:32 mpf Exp $ */
+/* $OpenBSD: if.c,v 1.21 2014/06/23 03:46:16 guenther Exp $ */
/*
* Copyright (c) 2004 Markus Friedl <markus@openbsd.org>
*
@@ -191,7 +191,7 @@ fetchifstat(void)
size_t need;
mib[0] = CTL_NET;
- mib[1] = AF_ROUTE;
+ mib[1] = PF_ROUTE;
mib[2] = 0;
mib[3] = 0;
mib[4] = NET_RT_IFLIST;