linux/tools/testing/selftests/seccomp
Jann Horn 2bfed7d2ff selftests/seccomp: Don't call read() on TTY from background pgrp
Since commit 92d25637a3 ("kselftest: signal all child processes"), tests
are executed in background process groups. This means that trying to read
from stdin now throws SIGTTIN when stdin is a TTY, which breaks some
seccomp selftests that try to use read(0, NULL, 0) as a dummy syscall.

The simplest way to fix that is probably to just use -1 instead of 0 as
the dummy read()'s FD.

Fixes: 92d25637a3 ("kselftest: signal all child processes")
Signed-off-by: Jann Horn <jannh@google.com>
Signed-off-by: Kees Cook <keescook@chromium.org>
Link: https://lore.kernel.org/r/20220319010011.1374622-1-jannh@google.com
2022-04-29 11:28:41 -07:00
..
.gitignore .gitignore: add SPDX License Identifier 2020-03-25 11:50:48 +01:00
config selftests/seccomp: Update kernel config 2020-12-02 11:20:54 -08:00
Makefile selftests/seccomp: Fix seccomp failure by adding missing headers 2022-02-14 11:14:38 -07:00
seccomp_benchmark.c selftests/seccomp: remove ARRAY_SIZE define from seccomp_benchmark 2021-12-10 17:51:09 -07:00
seccomp_bpf.c selftests/seccomp: Don't call read() on TTY from background pgrp 2022-04-29 11:28:41 -07:00
settings selftests/seccomp: Compare bitmap vs filter overhead 2020-11-20 11:16:34 -08:00