Handle broken PTRACE_EVENT_STOP values
For a few linux releases (3.1 through 3.3), this define in the exported
headers were broken. Redefine if that's the case.
* ptrace.h [PTRACE_EVENT_STOP]: Redefine if PTRACE_EVENT_STOP is 7.
diff --git a/ptrace.h b/ptrace.h
index 1a5414d..065cbda 100644
--- a/ptrace.h
+++ b/ptrace.h
@@ -50,6 +50,12 @@
#ifndef PTRACE_EVENT_SECCOMP
# define PTRACE_EVENT_SECCOMP 7
#endif
+#ifdef PTRACE_EVENT_STOP
+/* Linux 3.1 - 3.3 releases had a broken value. It was fixed in 3.4. */
+# if PTRACE_EVENT_STOP == 7
+# undef PTRACE_EVENT_STOP
+# endif
+#endif
#ifndef PTRACE_EVENT_STOP
# define PTRACE_EVENT_STOP 128
#endif