git: DragonFly_RELEASE_6_4 socket: Implement getsockopt(SO_ACCEPTCONN)
Aaron LI
aly at crater.dragonflybsd.org
Thu Nov 12 23:21:39 PST 2026
commit 42ffaeeb8937723b8c8e007a62fd0052e54d3464
Author: David Bidner <david at crap.solutions>
Date: Tue Oct 6 06:42:37 2026 +0200
socket: Implement getsockopt(SO_ACCEPTCONN)
SO_ACCEPTCONN is defined in <sys/socket.h>, but sogetopt() did not
handle it, so getsockopt(2) returned ENOPROTOOPT. FreeBSD, OpenBSD
and NetBSD all report it among the SOL_SOCKET options.
TigerVNC and similar servers probe this option to tell whether
their standard input is a connected socket or a listening socket
inherited from inetd "wait" mode. Without it, TigerVNC treats the
listening socket as connected, getpeername() fails with ENOTCONN,
and inetd respawns the server in a loop.
Add SO_ACCEPTCONN to the integer SOL_SOCKET option group, matching
FreeBSD (see commit dcb5fef5dbd4ca8488deff7a9074850d851bdc08).
Reported-by: Adrian KieÃ
Bug: https://bugs.dragonflybsd.org/issues/3300
Summary of changes:
sys/kern/uipc_socket.c | 1 +
1 file changed, 1 insertion(+)
http://gitweb.dragonflybsd.org/dragonfly.git/commitdiff/42ffaeeb8937723b8c8e007a62fd0052e54d3464
--
DragonFly BSD source repository
More information about the Commits
mailing list