Commit Graph
3 Commits
Author SHA1 Message Date
Queuze bbcce1736e fix(libkernel): support socket fcntl duplication 2026-10-20 13:40:22 +02:00
xXPBSXxandClaude Sonnet 5.5 c6dcead34c test(libkernel): check dup2 onto a guest socket in guest_socket_descriptor_flags
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-10-14 19:28:41 +02:00
xXPBSXxandClaude Sonnet 5.5 84aa2349f8 fix(libkernel): answer F_GETFD and F_SETFD on a guest socket
fcntl on a guest socket handled F_GETFL and F_SETFL only and failed every other command with EINVAL, so libcurl's fcntl(fd, F_SETFD, FD_CLOEXEC) on a new socket failed (ProsperoRadio PPSA99001, traced by screamm on #4796). Record FD_CLOEXEC per socket descriptor: F_SETFD sets or clears it, F_GETFD reads it, SOCK_CLOEXEC sets it at creation, and dup, dup2 and close start without it, as FreeBSD's kern_fcntl and kern_dup do.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-10-14 19:28:40 +02:00