diff options
Diffstat (limited to 'tools/testing/selftests/pidfd/pidfd_open_test.c')
-rw-r--r-- | tools/testing/selftests/pidfd/pidfd_open_test.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/tools/testing/selftests/pidfd/pidfd_open_test.c b/tools/testing/selftests/pidfd/pidfd_open_test.c index 8a59438ccc..c62564c264 100644 --- a/tools/testing/selftests/pidfd/pidfd_open_test.c +++ b/tools/testing/selftests/pidfd/pidfd_open_test.c @@ -159,5 +159,7 @@ on_error: if (pidfd >= 0) close(pidfd); - return !ret ? ksft_exit_pass() : ksft_exit_fail(); + if (ret) + ksft_exit_fail(); + ksft_exit_pass(); } |