[LTP] [PATCH] syscalls/ptrace07.c: Fix compilation without WIFEXITED and WEXITSTATUS

Jinhui Huang huangjh.jy@cn.fujitsu.com
Thu Oct 26 05:44:47 CEST 2017


Compilation failed on some older distributions due to undefined
WIFEXITED and WEXITSTATUS, so we include sys/wait.h to fix it.

Signed-off-by: Jinhui Huang <huangjh.jy@cn.fujitsu.com>
---
 testcases/kernel/syscalls/ptrace/ptrace07.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/testcases/kernel/syscalls/ptrace/ptrace07.c b/testcases/kernel/syscalls/ptrace/ptrace07.c
index d561b30..82698a4 100644
--- a/testcases/kernel/syscalls/ptrace/ptrace07.c
+++ b/testcases/kernel/syscalls/ptrace/ptrace07.c
@@ -42,6 +42,7 @@
 #include <stdbool.h>
 #include <stdlib.h>
 #include <sys/uio.h>
+#include <sys/wait.h>
 
 #include "config.h"
 #include "ptrace.h"
-- 
1.8.3.1





More information about the ltp mailing list