aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPawel Biernacki <kaktus@FreeBSD.org>2020-01-02 01:23:43 +0000
committerPawel Biernacki <kaktus@FreeBSD.org>2020-01-02 01:23:43 +0000
commite8cdbb4815a458cf599de91ce0d161796c8fc2aa (patch)
tree5b4c1c7c0f17b4c86fe899d0653b9487788a08d8
parent57db0e12c817b6e98b3cf1492b8447057761a0ed (diff)
downloadsrc-e8cdbb4815a458cf599de91ce0d161796c8fc2aa.tar.gz
src-e8cdbb4815a458cf599de91ce0d161796c8fc2aa.zip
sysctl: hide 2.x era compat node
r23081 introduced kern.dummy oid as a semi ABI compat for kern.maxsockbuf that was moved to a new namespace. It never functioned as an alias of any kind and was just returning 0 unconditionally, hence it was probably provided to keep some 3rd party programmes happy about sysctl(3) not reporting an error because of non-existing oid. After nearly 23 years it seems reasonable to just hide it from sysctl(8) list not to cause unnecessary confusion as for its purpose. Reported by: Antranig Vartanian <antranigv@freebsd.am> Reviewed by: kib (mentor) Approved by: kib (mentor) Differential Revision: https://reviews.freebsd.org/D22982
Notes
Notes: svn path=/head/; revision=356262
-rw-r--r--sys/kern/uipc_sockbuf.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/sys/kern/uipc_sockbuf.c b/sys/kern/uipc_sockbuf.c
index 3a43ee873791..6cc81089719d 100644
--- a/sys/kern/uipc_sockbuf.c
+++ b/sys/kern/uipc_sockbuf.c
@@ -1522,7 +1522,7 @@ sbtoxsockbuf(struct sockbuf *sb, struct xsockbuf *xsb)
/* This takes the place of kern.maxsockbuf, which moved to kern.ipc. */
static int dummy;
-SYSCTL_INT(_kern, KERN_DUMMY, dummy, CTLFLAG_RW, &dummy, 0, "");
+SYSCTL_INT(_kern, KERN_DUMMY, dummy, CTLFLAG_RW | CTLFLAG_SKIP, &dummy, 0, "");
SYSCTL_OID(_kern_ipc, KIPC_MAXSOCKBUF, maxsockbuf, CTLTYPE_ULONG|CTLFLAG_RW,
&sb_max, 0, sysctl_handle_sb_max, "LU", "Maximum socket buffer size");
SYSCTL_ULONG(_kern_ipc, KIPC_SOCKBUF_WASTE, sockbuf_waste_factor, CTLFLAG_RW,