WSL2-Linux-Kernel/tools/testing/selftests/clone3
Axel Rasmussen 54d69f072d selftests: fixup build warnings in pidfd / clone3 tests
[ Upstream commit e2aa5e650b ]

These are some trivial fixups, which were needed to build the tests with
clang and -Werror. The following issues are fixed:

- Remove various unused variables.
- In child_poll_leader_exit_test, clang isn't smart enough to realize
  syscall(SYS_exit, 0) won't return, so it complains we never return
  from a non-void function. Add an extra exit(0) to appease it.
- In test_pidfd_poll_leader_exit, ret may be branched on despite being
  uninitialized, if we have !use_waitpid. Initialize it to zero to get
  the right behavior in that case.

Signed-off-by: Axel Rasmussen <axelrasmussen@google.com>
Acked-by: Christian Brauner <brauner@kernel.org>
Signed-off-by: Shuah Khan <skhan@linuxfoundation.org>
Signed-off-by: Sasha Levin <sashal@kernel.org>
2022-02-23 12:03:18 +01:00
..
.gitignore selftests: add clone3() CAP_CHECKPOINT_RESTORE test 2020-07-20 15:47:42 +02:00
Makefile selftests/clone3: Fix build error 2020-12-07 14:34:55 -07:00
clone3.c selftests: fixup build warnings in pidfd / clone3 tests 2022-02-23 12:03:18 +01:00
clone3_cap_checkpoint_restore.c selftests: clone3: use SKIP instead of XFAIL 2020-11-05 10:08:15 -07:00
clone3_clear_sighand.c selftests/clone3: Avoid OS-defined clone_args 2020-10-08 13:17:25 -07:00
clone3_selftests.h selftests/clone3: Avoid OS-defined clone_args 2020-10-08 13:17:25 -07:00
clone3_set_tid.c selftests/clone3: Avoid OS-defined clone_args 2020-10-08 13:17:25 -07:00