From: Mike Frysinger Date: Thu, 2 May 2013 19:43:45 +0000 (-0400) Subject: test: include headers for used funcs X-Git-Tag: v4.8~55 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=b51ce624548b13aeead20cf519567a1ee9349749;p=strace test: include headers for used funcs These funcs use things like wait/write/read/strcmp but sometimes don't include the right header for them. * test/Makefile: Add -Wall to CFLAGS. * test/clone.c: Include unistd.h. * test/fork.c: Include sys/wait.h. * test/sig.c: Include unistd.h. * test/sigkill_rain.c: Include sys/wait.h. * test/vfork.c: Include sys/wait.h. * test/wait_must_be_interruptible.c: Include string.h --- diff --git a/test/Makefile b/test/Makefile index c6ce99cd..781e1f68 100644 --- a/test/Makefile +++ b/test/Makefile @@ -1,3 +1,5 @@ +CFLAGS += -Wall + all: \ vfork fork sig skodic clone leaderkill childthread \ sigkill_rain wait_must_be_interruptible threaded_execve diff --git a/test/clone.c b/test/clone.c index 5de302f8..bdce8b19 100644 --- a/test/clone.c +++ b/test/clone.c @@ -4,6 +4,7 @@ #include #include #include +#include int child(void* arg) { diff --git a/test/fork.c b/test/fork.c index 9bed1fe4..1425e2dd 100644 --- a/test/fork.c +++ b/test/fork.c @@ -1,5 +1,6 @@ #include #include +#include int main(int argc, char *argv[]) { diff --git a/test/sig.c b/test/sig.c index 60a9dc9e..1678b022 100644 --- a/test/sig.c +++ b/test/sig.c @@ -1,5 +1,6 @@ #include #include +#include void interrupt() { diff --git a/test/sigkill_rain.c b/test/sigkill_rain.c index e2350dbd..59af55b2 100644 --- a/test/sigkill_rain.c +++ b/test/sigkill_rain.c @@ -5,6 +5,7 @@ #include #include #include +#include static const struct sockaddr sa; diff --git a/test/vfork.c b/test/vfork.c index 367dc019..f49a4733 100644 --- a/test/vfork.c +++ b/test/vfork.c @@ -1,5 +1,6 @@ #include #include +#include int main(int argc, char *argv[]) { diff --git a/test/wait_must_be_interruptible.c b/test/wait_must_be_interruptible.c index 931ec4ce..3fb34497 100644 --- a/test/wait_must_be_interruptible.c +++ b/test/wait_must_be_interruptible.c @@ -3,6 +3,7 @@ #include #include #include +#include /* Expected order is: * Child signals parent