diff options
author | Dmitry V. Levin <ldv@altlinux.org> | 2018-02-11 00:26:09 +0000 |
---|---|---|
committer | Dmitry V. Levin <ldv@altlinux.org> | 2018-02-11 00:26:09 +0000 |
commit | 5a6dff3fe886c275d3efe6a81e1ba5b949f1d52c (patch) | |
tree | a75d1606781e9767562d577c740478587904047d /tests/ptrace.c | |
parent | f2bb704a92ade4668e4e0ae45e55cc60bf94514c (diff) | |
download | strace-5a6dff3fe886c275d3efe6a81e1ba5b949f1d52c.tar.gz |
Include <sys/ptrace.h> early
Include "ptrace.h" before any header that can include <signal.h>
because on some architectures the latter may include <asm/sigcontext.h>
which in turn may include <asm/ptrace.h> with potentially devastating
effect on <sys/ptrace.h>.
* process.c: Include "ptrace.h" before "regs.h".
* rt_sigframe.c: Likewise.
* sigreturn.c: Include "ptrace.h" before "nsig.h".
* syscall.c: Likewise.
* wait.c: Include "ptrace.h" before <sys/wait.h>.
* strace.c: Include "ptrace.h" before <signal.h>.
* tests/ptrace.c: Likewise.
* tests/test_ucopy.c: Include <sys/ptrace.h> before <signal.h>.
Diffstat (limited to 'tests/ptrace.c')
-rw-r--r-- | tests/ptrace.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/tests/ptrace.c b/tests/ptrace.c index d776dcdd2..0f008d937 100644 --- a/tests/ptrace.c +++ b/tests/ptrace.c @@ -32,12 +32,12 @@ #include <asm/unistd.h> #include <errno.h> +#include "ptrace.h" #include <signal.h> #include <stdio.h> #include <string.h> #include <sys/wait.h> #include <unistd.h> -#include "ptrace.h" #include <linux/audit.h> static const char *errstr; |