opnsense-src/tests/sys/kern
Gleb Smirnoff cfb1e92912 sockets: don't malloc/free sockaddr memory on accept(2)
Let the accept functions provide stack memory for protocols to fill it in.
Generic code should provide sockaddr_storage, specialized code may provide
smaller structure.

While rewriting accept(2) make 'addrlen' a true in/out parameter, reporting
required length in case if provided length was insufficient.  Our manual
page accept(2) and POSIX don't explicitly require that, but one can read
the text as they do.  Linux also does that. Update tests accordingly.

Reviewed by:		rscheff, tuexen, zlei, dchagin
Differential Revision:	https://reviews.freebsd.org/D42635
2023-11-30 08:30:55 -08:00
..
acct tests: Automated cleanup of cdefs and other formatting 2023-11-26 22:24:01 -07:00
execve Remove $FreeBSD$: one-line sh pattern 2023-08-16 11:55:03 -06:00
pipe tests: Automated cleanup of cdefs and other formatting 2023-11-26 22:24:01 -07:00
basic_signal.c Reenable basic_signal:trap_signal_test on i386 2022-08-25 12:09:00 +08:00
coredump_phnum_helper.c Remove $FreeBSD$: two-line .h pattern 2023-08-16 11:54:16 -06:00
coredump_phnum_test.sh Remove $FreeBSD$: one-line sh pattern 2023-08-16 11:55:03 -06:00
fdgrowtable_test.c tests: Automated cleanup of cdefs and other formatting 2023-11-26 22:24:01 -07:00
kcov.c tests: Automated cleanup of cdefs and other formatting 2023-11-26 22:24:01 -07:00
kern_copyin.c tests: Automated cleanup of cdefs and other formatting 2023-11-26 22:24:01 -07:00
kern_descrip_test.c tests: Automated cleanup of cdefs and other formatting 2023-11-26 22:24:01 -07:00
kill_zombie.c Remove $FreeBSD$: one-line .c pattern 2023-08-16 11:54:42 -06:00
ktls_test.c ktls tests: Relax error checking for shutdown(2) a bit 2023-11-17 09:31:21 -05:00
libkern_crc32.c Remove $FreeBSD$: two-line .h pattern 2023-08-16 11:54:16 -06:00
Makefile socket tests: add socket_accept 2023-11-16 08:23:48 -08:00
Makefile.depend Remove $FreeBSD$: one-line sh pattern 2023-08-16 11:55:03 -06:00
Makefile.inc Remove $FreeBSD$: one-line sh pattern 2023-08-16 11:55:03 -06:00
module_test.c module_test: Fix some assignments to errno intended to be tests. 2022-03-14 14:05:05 -07:00
pdeathsig.c Remove $FreeBSD$: one-line .c pattern 2023-08-16 11:54:42 -06:00
pdeathsig_helper.c Remove $FreeBSD$: one-line .c pattern 2023-08-16 11:54:42 -06:00
ptrace_test.c tests: Automated cleanup of cdefs and other formatting 2023-11-26 22:24:01 -07:00
reaper.c Remove $FreeBSD$: one-line .c pattern 2023-08-16 11:54:42 -06:00
sched_affinity.c tests: Automated cleanup of cdefs and other formatting 2023-11-26 22:24:01 -07:00
sendfile_helper.c Remove $FreeBSD$: two-line .h pattern 2023-08-16 11:54:16 -06:00
sendfile_test.sh tests: don't run atf_* in a subshell 2023-11-27 13:15:59 -08:00
sigaltstack.c Remove $FreeBSD$: one-line .c pattern 2023-08-16 11:54:42 -06:00
sigsys.c tests: Test that SIGSYS is not delivered if kern.signosys knob is off 2023-10-03 10:38:02 +03:00
sigwait.c Remove $FreeBSD$: one-line .c pattern 2023-08-16 11:54:42 -06:00
socket_accept.c sockets: don't malloc/free sockaddr memory on accept(2) 2023-11-30 08:30:55 -08:00
socket_accf.c tests/socket: add accept_filter(9) test 2022-08-08 14:10:18 -07:00
socket_msg_trunc.c socket tests: Build fix 2023-10-17 10:22:11 -04:00
socket_msg_waitall.c socket tests: Avoid a buffer leak 2023-09-27 08:30:50 -04:00
sonewconn_overflow.py Remove $FreeBSD$: one-line sh pattern 2023-08-16 11:55:03 -06:00
sonewconn_overflow.sh Remove $FreeBSD$: one-line sh pattern 2023-08-16 11:55:03 -06:00
subr_physmem_test.c tests: Automated cleanup of cdefs and other formatting 2023-11-26 22:24:01 -07:00
sys_getrandom.c tests: Automated cleanup of cdefs and other formatting 2023-11-26 22:24:01 -07:00
sysctl_kern_proc.c spdx: The BSD-2-Clause-FreeBSD identifier is obsolete, drop -FreeBSD 2023-05-12 10:44:03 -06:00
unix_dgram.c unix tests: Add a regression test for getpeername(2) 2023-06-21 14:39:36 -04:00
unix_passfd_dgram.c tests/unix_passfd: compile SOCK_STREAM and SOCK_DGRAM versions 2022-06-24 09:09:11 -07:00
unix_passfd_stream.c tests/unix_passfd: compile SOCK_STREAM and SOCK_DGRAM versions 2022-06-24 09:09:11 -07:00
unix_passfd_test.c tests: Automated cleanup of cdefs and other formatting 2023-11-26 22:24:01 -07:00
unix_seqpacket_test.c Remove $FreeBSD$: one-line .c pattern 2023-08-16 11:54:42 -06:00
unix_socketpair_test.c Remove $FreeBSD$: one-line .c pattern 2023-08-16 11:54:42 -06:00
waitpid_nohang.c Remove $FreeBSD$: one-line .c pattern 2023-08-16 11:54:42 -06:00