aboutsummaryrefslogtreecommitdiff
path: root/lib
diff options
context:
space:
mode:
authorMichael Tuexen <tuexen@FreeBSD.org>2022-10-12 02:33:00 +0000
committerMichael Tuexen <tuexen@FreeBSD.org>2022-10-12 02:33:00 +0000
commitbc0d4076763624df7c3ab35862bc571a3cf80748 (patch)
tree9390d4062b8c6c892f175721334a582fed2c452c /lib
parent5d56371c70d785c222ff086ba8a83b408111acbf (diff)
downloadsrc-bc0d4076763624df7c3ab35862bc571a3cf80748.tar.gz
src-bc0d4076763624df7c3ab35862bc571a3cf80748.zip
Revert "listen(): improve POSIX compliance"
This reverts commit 76e6e4d72f8d3da7d19242f303bc95461fde7fb9. Several programs in the tree use -1 instead of INT_MAX to use the maximum value. Thanks to Eugene Grosbein for pointing this out.
Diffstat (limited to 'lib')
-rw-r--r--lib/libc/sys/listen.212
1 files changed, 2 insertions, 10 deletions
diff --git a/lib/libc/sys/listen.2 b/lib/libc/sys/listen.2
index ad4d6edf228f..4d0962fd412c 100644
--- a/lib/libc/sys/listen.2
+++ b/lib/libc/sys/listen.2
@@ -28,7 +28,7 @@
.\" From: @(#)listen.2 8.2 (Berkeley) 12/11/93
.\" $FreeBSD$
.\"
-.Dd October 11, 2022
+.Dd April 14, 2020
.Dt LISTEN 2
.Os
.Sh NAME
@@ -106,13 +106,10 @@ specifies a hard limit on
.Fa backlog ;
if a value greater than
.Va kern.ipc.soacceptqueue
-is specified,
+or less than zero is specified,
.Fa backlog
is silently forced to
.Va kern.ipc.soacceptqueue .
-If a negative value is used,
-.Fa backlog
-is silently forced to 0.
.Pp
If the listen queue overflows, the kernel will emit a LOG_DEBUG syslog message.
The
@@ -194,8 +191,3 @@ The original
is still available but hidden from a
.Xr sysctl 3
-a output so that existing applications and scripts continue to work.
-To improve POSIX compliance, a negative
-.Fa backlog
-argument is handled the same as 0.
-This was introduced in
-.Fx 14.0 .