diff options
author | Philip Guenther <guenther@cvs.openbsd.org> | 2014-06-23 03:46:18 +0000 |
---|---|---|
committer | Philip Guenther <guenther@cvs.openbsd.org> | 2014-06-23 03:46:18 +0000 |
commit | c39cf5c6337d9356a175b97eb0b3aedccfd86181 (patch) | |
tree | 917a8723e1c99419650984b52371ff89efa1bdb8 /usr.sbin | |
parent | fa550c5927b364008a8192d7c1b2a720e9036960 (diff) |
The second level of the CTL_NET sysctl is a PF_*, not an AF_*
inconsistent usage in route(8) noted by Gregor Best (gbe (at) ring0.de)
Diffstat (limited to 'usr.sbin')
-rw-r--r-- | usr.sbin/bgpd/kroute.c | 8 | ||||
-rw-r--r-- | usr.sbin/dvmrpd/kroute.c | 4 | ||||
-rw-r--r-- | usr.sbin/ldpd/kroute.c | 6 | ||||
-rw-r--r-- | usr.sbin/ospf6d/kroute.c | 6 | ||||
-rw-r--r-- | usr.sbin/ospfd/kroute.c | 6 | ||||
-rw-r--r-- | usr.sbin/ripd/kroute.c | 6 | ||||
-rw-r--r-- | usr.sbin/snmpd/kroute.c | 10 | ||||
-rw-r--r-- | usr.sbin/snmpd/mib.c | 12 |
8 files changed, 29 insertions, 29 deletions
diff --git a/usr.sbin/bgpd/kroute.c b/usr.sbin/bgpd/kroute.c index 5847f431ea8..5681f22f57f 100644 --- a/usr.sbin/bgpd/kroute.c +++ b/usr.sbin/bgpd/kroute.c @@ -1,4 +1,4 @@ -/* $OpenBSD: kroute.c,v 1.197 2014/01/23 23:26:56 benno Exp $ */ +/* $OpenBSD: kroute.c,v 1.198 2014/06/23 03:46:17 guenther Exp $ */ /* * Copyright (c) 2003, 2004 Henning Brauer <henning@openbsd.org> @@ -436,7 +436,7 @@ ktable_exists(u_int rtableid, u_int *rdomid) int mib[6]; mib[0] = CTL_NET; - mib[1] = AF_ROUTE; + mib[1] = PF_ROUTE; mib[2] = 0; mib[3] = 0; mib[4] = NET_RT_TABLE; @@ -2782,7 +2782,7 @@ fetchtable(struct ktable *kt, u_int8_t fib_prio) struct kroute6_node *kr6 = NULL; mib[0] = CTL_NET; - mib[1] = AF_ROUTE; + mib[1] = PF_ROUTE; mib[2] = 0; mib[3] = 0; mib[4] = NET_RT_DUMP; @@ -2948,7 +2948,7 @@ fetchifs(int ifindex) struct sockaddr_dl *sdl; mib[0] = CTL_NET; - mib[1] = AF_ROUTE; + mib[1] = PF_ROUTE; mib[2] = 0; mib[3] = AF_INET; /* AF does not matter but AF_INET is shorter */ mib[4] = NET_RT_IFLIST; diff --git a/usr.sbin/dvmrpd/kroute.c b/usr.sbin/dvmrpd/kroute.c index 40699627cf6..d958a376d50 100644 --- a/usr.sbin/dvmrpd/kroute.c +++ b/usr.sbin/dvmrpd/kroute.c @@ -1,4 +1,4 @@ -/* $OpenBSD: kroute.c,v 1.7 2011/07/04 04:34:14 claudio Exp $ */ +/* $OpenBSD: kroute.c,v 1.8 2014/06/23 03:46:17 guenther Exp $ */ /* * Copyright (c) 2004 Esben Norby <norby@openbsd.org> @@ -305,7 +305,7 @@ fetchifs(int ifindex) struct sockaddr_dl *sdl; mib[0] = CTL_NET; - mib[1] = AF_ROUTE; + mib[1] = PF_ROUTE; mib[2] = 0; mib[3] = AF_INET; mib[4] = NET_RT_IFLIST; diff --git a/usr.sbin/ldpd/kroute.c b/usr.sbin/ldpd/kroute.c index 28c183598af..e55a03f15fb 100644 --- a/usr.sbin/ldpd/kroute.c +++ b/usr.sbin/ldpd/kroute.c @@ -1,4 +1,4 @@ -/* $OpenBSD: kroute.c,v 1.32 2013/10/30 17:24:34 deraadt Exp $ */ +/* $OpenBSD: kroute.c,v 1.33 2014/06/23 03:46:17 guenther Exp $ */ /* * Copyright (c) 2009 Michele Marchetto <michele@openbsd.org> @@ -1104,7 +1104,7 @@ fetchtable(void) int rv; mib[0] = CTL_NET; - mib[1] = AF_ROUTE; + mib[1] = PF_ROUTE; mib[2] = 0; mib[3] = AF_INET; mib[4] = NET_RT_DUMP; @@ -1140,7 +1140,7 @@ fetchifs(u_short ifindex) int rv; mib[0] = CTL_NET; - mib[1] = AF_ROUTE; + mib[1] = PF_ROUTE; mib[2] = 0; mib[3] = AF_INET; mib[4] = NET_RT_IFLIST; diff --git a/usr.sbin/ospf6d/kroute.c b/usr.sbin/ospf6d/kroute.c index 6968a12fe13..2931d68418a 100644 --- a/usr.sbin/ospf6d/kroute.c +++ b/usr.sbin/ospf6d/kroute.c @@ -1,4 +1,4 @@ -/* $OpenBSD: kroute.c,v 1.43 2013/10/30 17:24:34 deraadt Exp $ */ +/* $OpenBSD: kroute.c,v 1.44 2014/06/23 03:46:17 guenther Exp $ */ /* * Copyright (c) 2004 Esben Norby <norby@openbsd.org> @@ -1059,7 +1059,7 @@ fetchtable(void) struct kroute_node *kr; mib[0] = CTL_NET; - mib[1] = AF_ROUTE; + mib[1] = PF_ROUTE; mib[2] = 0; mib[3] = AF_INET6; mib[4] = NET_RT_DUMP; @@ -1182,7 +1182,7 @@ fetchifs(u_short ifindex) struct sockaddr *sa, *rti_info[RTAX_MAX]; mib[0] = CTL_NET; - mib[1] = AF_ROUTE; + mib[1] = PF_ROUTE; mib[2] = 0; mib[3] = AF_INET6; mib[4] = NET_RT_IFLIST; diff --git a/usr.sbin/ospfd/kroute.c b/usr.sbin/ospfd/kroute.c index cdc697fb98c..c4c72a54f37 100644 --- a/usr.sbin/ospfd/kroute.c +++ b/usr.sbin/ospfd/kroute.c @@ -1,4 +1,4 @@ -/* $OpenBSD: kroute.c,v 1.93 2013/10/30 17:24:35 deraadt Exp $ */ +/* $OpenBSD: kroute.c,v 1.94 2014/06/23 03:46:17 guenther Exp $ */ /* * Copyright (c) 2004 Esben Norby <norby@openbsd.org> @@ -1237,7 +1237,7 @@ fetchtable(void) int rv; mib[0] = CTL_NET; - mib[1] = AF_ROUTE; + mib[1] = PF_ROUTE; mib[2] = 0; mib[3] = AF_INET; mib[4] = NET_RT_DUMP; @@ -1273,7 +1273,7 @@ fetchifs(u_short ifindex) int rv; mib[0] = CTL_NET; - mib[1] = AF_ROUTE; + mib[1] = PF_ROUTE; mib[2] = 0; mib[3] = AF_INET; mib[4] = NET_RT_IFLIST; diff --git a/usr.sbin/ripd/kroute.c b/usr.sbin/ripd/kroute.c index cbe107036ee..619e885b21d 100644 --- a/usr.sbin/ripd/kroute.c +++ b/usr.sbin/ripd/kroute.c @@ -1,4 +1,4 @@ -/* $OpenBSD: kroute.c,v 1.24 2011/07/04 04:34:14 claudio Exp $ */ +/* $OpenBSD: kroute.c,v 1.25 2014/06/23 03:46:17 guenther Exp $ */ /* * Copyright (c) 2004 Esben Norby <norby@openbsd.org> @@ -817,7 +817,7 @@ fetchtable(void) struct iface *iface = NULL; mib[0] = CTL_NET; - mib[1] = AF_ROUTE; + mib[1] = PF_ROUTE; mib[2] = 0; mib[3] = AF_INET; mib[4] = NET_RT_DUMP; @@ -943,7 +943,7 @@ fetchifs(int ifindex) struct sockaddr_dl *sdl; mib[0] = CTL_NET; - mib[1] = AF_ROUTE; + mib[1] = PF_ROUTE; mib[2] = 0; mib[3] = AF_INET; mib[4] = NET_RT_IFLIST; diff --git a/usr.sbin/snmpd/kroute.c b/usr.sbin/snmpd/kroute.c index 5d8023a8674..79090f155e0 100644 --- a/usr.sbin/snmpd/kroute.c +++ b/usr.sbin/snmpd/kroute.c @@ -1,4 +1,4 @@ -/* $OpenBSD: kroute.c,v 1.27 2014/05/16 08:46:23 mikeb Exp $ */ +/* $OpenBSD: kroute.c,v 1.28 2014/06/23 03:46:17 guenther Exp $ */ /* * Copyright (c) 2007, 2008 Reyk Floeter <reyk@openbsd.org> @@ -320,7 +320,7 @@ ktable_exists(u_int rtableid, u_int *rdomid) int mib[6]; mib[0] = CTL_NET; - mib[1] = AF_ROUTE; + mib[1] = PF_ROUTE; mib[2] = 0; mib[3] = 0; mib[4] = NET_RT_TABLE; @@ -1188,7 +1188,7 @@ fetchtable(struct ktable *kt) int rv; mib[0] = CTL_NET; - mib[1] = AF_ROUTE; + mib[1] = PF_ROUTE; mib[2] = 0; mib[3] = AF_INET; mib[4] = NET_RT_DUMP; @@ -1231,7 +1231,7 @@ fetchifs(u_short if_index) int rv; mib[0] = CTL_NET; - mib[1] = AF_ROUTE; + mib[1] = PF_ROUTE; mib[2] = 0; mib[3] = 0; /* wildcard address family */ mib[4] = NET_RT_IFLIST; @@ -1268,7 +1268,7 @@ fetcharp(struct ktable *kt) int rv; mib[0] = CTL_NET; - mib[1] = AF_ROUTE; + mib[1] = PF_ROUTE; mib[2] = 0; mib[3] = AF_INET; mib[4] = NET_RT_FLAGS; diff --git a/usr.sbin/snmpd/mib.c b/usr.sbin/snmpd/mib.c index f92d2612d85..96c9681b575 100644 --- a/usr.sbin/snmpd/mib.c +++ b/usr.sbin/snmpd/mib.c @@ -1,4 +1,4 @@ -/* $OpenBSD: mib.c,v 1.69 2014/05/07 01:23:52 tedu Exp $ */ +/* $OpenBSD: mib.c,v 1.70 2014/06/23 03:46:17 guenther Exp $ */ /* * Copyright (c) 2012 Joel Knight <joel@openbsd.org> @@ -1082,7 +1082,7 @@ mib_iftable(struct oid *oid, struct ber_oid *o, struct ber_element **elm) long long i; size_t len; int ifq; - int mib[] = { CTL_NET, AF_INET, IPPROTO_IP, 0, 0 }; + int mib[] = { CTL_NET, PF_INET, IPPROTO_IP, 0, 0 }; /* Get and verify the current row index */ idx = o->bo_id[OIDIDX_ifEntry]; @@ -2461,7 +2461,7 @@ int mib_pfsyncstats(struct oid *oid, struct ber_oid *o, struct ber_element **elm) { int i; - int mib[] = { CTL_NET, AF_INET, IPPROTO_PFSYNC, + int mib[] = { CTL_NET, PF_INET, IPPROTO_PFSYNC, PFSYNCCTL_STATS }; size_t len = sizeof(struct pfsyncstats); struct pfsyncstats s; @@ -2979,7 +2979,7 @@ static struct oid ip_mib[] = { int mib_ipforwarding(struct oid *oid, struct ber_oid *o, struct ber_element **elm) { - int mib[] = { CTL_NET, AF_INET, IPPROTO_IP, IPCTL_FORWARDING }; + int mib[] = { CTL_NET, PF_INET, IPPROTO_IP, IPCTL_FORWARDING }; int v; size_t len = sizeof(v); @@ -2994,7 +2994,7 @@ mib_ipforwarding(struct oid *oid, struct ber_oid *o, struct ber_element **elm) int mib_ipdefaultttl(struct oid *oid, struct ber_oid *o, struct ber_element **elm) { - int mib[] = { CTL_NET, AF_INET, IPPROTO_IP, IPCTL_DEFTTL }; + int mib[] = { CTL_NET, PF_INET, IPPROTO_IP, IPCTL_DEFTTL }; int v; size_t len = sizeof(v); @@ -3009,7 +3009,7 @@ mib_ipdefaultttl(struct oid *oid, struct ber_oid *o, struct ber_element **elm) int mib_getipstat(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); return (sysctl(mib, sizeofa(mib), ipstat, &len, NULL, 0)); |