mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
synced 2026-05-21 10:15:22 -04:00
Add selftests to verify and document Linux’s intended behaviour for UNIX domain sockets (SOCK_STREAM and SOCK_DGRAM) when a peer closes. The tests verify that: 1. SOCK_STREAM returns EOF when the peer closes normally. 2. SOCK_STREAM returns ECONNRESET if the peer closes with unread data. 3. SOCK_SEQPACKET returns EOF when the peer closes normally. 4. SOCK_SEQPACKET returns ECONNRESET if the peer closes with unread data. 5. SOCK_DGRAM does not return ECONNRESET when the peer closes. This follows up on review feedback suggesting a selftest to clarify Linux’s semantics. Suggested-by: Kuniyuki Iwashima <kuniyu@google.com> Signed-off-by: Sunday Adelodun <adelodunolaoluwa@yahoo.com> Link: https://patch.msgid.link/20251113112802.44657-1-adelodunolaoluwa@yahoo.com Signed-off-by: Paolo Abeni <pabeni@redhat.com>
14 lines
226 B
Makefile
14 lines
226 B
Makefile
CFLAGS += $(KHDR_INCLUDES) -Wall -Wflex-array-member-not-at-end
|
|
|
|
TEST_GEN_PROGS := \
|
|
diag_uid \
|
|
msg_oob \
|
|
scm_inq \
|
|
scm_pidfd \
|
|
scm_rights \
|
|
unix_connect \
|
|
unix_connreset \
|
|
# end of TEST_GEN_PROGS
|
|
|
|
include ../../lib.mk
|