aboutsummaryrefslogtreecommitdiff
path: root/sys/net/vnet.h
diff options
context:
space:
mode:
authorMatthew D Fleming <mdf@FreeBSD.org>2011-01-19 17:04:07 +0000
committerMatthew D Fleming <mdf@FreeBSD.org>2011-01-19 17:04:07 +0000
commitf8e4b4ef49d1e146c54e7711f954d63d729fbb8e (patch)
tree5e1c41064fb9146dbfbbbd14965e9bed5fb07985 /sys/net/vnet.h
parent08b1d5357309bcddf6f6cc577c009374c05eb17a (diff)
downloadsrc-f8e4b4ef49d1e146c54e7711f954d63d729fbb8e.tar.gz
src-f8e4b4ef49d1e146c54e7711f954d63d729fbb8e.zip
sysctl(8) should use the CTLTYPE to determine the type of data when
reading. (This was already done for writing to a sysctl). This requires all SYSCTL setups to specify a type. Most of them are now checked at compile-time. Remove SYSCTL_*X* sysctl additions as the print being in hex should be controlled by the -x flag to sysctl(8). Succested by: bde
Notes
Notes: svn path=/head/; revision=217586
Diffstat (limited to 'sys/net/vnet.h')
-rw-r--r--sys/net/vnet.h1
1 files changed, 1 insertions, 0 deletions
diff --git a/sys/net/vnet.h b/sys/net/vnet.h
index 76123c7e4b88..9292145712af 100644
--- a/sys/net/vnet.h
+++ b/sys/net/vnet.h
@@ -236,6 +236,7 @@ int vnet_sysctl_handle_uint(SYSCTL_HANDLER_ARGS);
ptr, val, vnet_sysctl_handle_int, "I", descr)
#define SYSCTL_VNET_PROC(parent, nbr, name, access, ptr, arg, handler, \
fmt, descr) \
+ CTASSERT(((access) & CTLTYPE) != 0); \
SYSCTL_OID(parent, nbr, name, CTLFLAG_VNET|(access), ptr, arg, \
handler, fmt, descr)
#define SYSCTL_VNET_OPAQUE(parent, nbr, name, access, ptr, len, fmt, \