From: Andy Lutomirski Date: Wed, 26 Aug 2020 17:00:45 +0000 (-0700) Subject: selftests/x86/fsgsbase: Reap a forgotten child X-Git-Tag: io_uring-5.10-2020-10-20~138^2~1 X-Git-Url: https://git.kernel.dk/?a=commitdiff_plain;h=ab2dd173330a3f07142e68cd65682205036cd00f;p=linux-block.git selftests/x86/fsgsbase: Reap a forgotten child The ptrace() test forgot to reap its child. Reap it. Signed-off-by: Andy Lutomirski Signed-off-by: Ingo Molnar Link: https://lore.kernel.org/r/e7700a503f30e79ab35a63103938a19893dbeff2.1598461151.git.luto@kernel.org --- diff --git a/tools/testing/selftests/x86/fsgsbase.c b/tools/testing/selftests/x86/fsgsbase.c index 998319553523..0056e2597f53 100644 --- a/tools/testing/selftests/x86/fsgsbase.c +++ b/tools/testing/selftests/x86/fsgsbase.c @@ -517,6 +517,9 @@ static void test_ptrace_write_gsbase(void) END: ptrace(PTRACE_CONT, child, NULL, NULL); + wait(&status); + if (!WIFEXITED(status)) + printf("[WARN]\tChild didn't exit cleanly.\n"); } int main()