Set SA_RESTORER in sigaction()
GDB looks for specific opcode sequences when trying to recognize a stack
frame as a signal trampoline. The sequences it looks for happen to be those
created when SA_RESTORER is set, since glibc always sets a restorer. This
patch does the same here, so that the trampolines can be correctly identified.
Change-Id: I0ac574a68818cb24d939c3527f3aaeb04b853d04
diff --git a/libc/SYSCALLS.TXT b/libc/SYSCALLS.TXT
index 684b43e..eaeea2b 100644
--- a/libc/SYSCALLS.TXT
+++ b/libc/SYSCALLS.TXT
@@ -167,7 +167,7 @@
int utimes(const char*, const struct timeval tvp[2]) 269, 271
# signals
-int sigaction(int, const struct sigaction *, struct sigaction *) 67
+int sigaction(int, const struct sigaction *, struct sigaction *) -1,67,67
int sigprocmask(int, const sigset_t *, sigset_t *) 126
int __sigsuspend:sigsuspend(int unused1, int unused2, unsigned mask) 72
int __rt_sigaction:rt_sigaction (int sig, const struct sigaction *act, struct sigaction *oact, size_t sigsetsize) 174
@@ -175,6 +175,9 @@
int __rt_sigtimedwait:rt_sigtimedwait(const sigset_t *set, struct siginfo_t *info, struct timespec_t *timeout, size_t sigset_size) 177
int sigpending(sigset_t *) 73
+# special stub for ARM, see arch-arm/bionic/sigaction.c
+int __sigaction:sigaction(int, const struct sigaction *, struct sigaction *) 67,-1,-1
+
# sockets
int socket(int, int, int) 281,-1
int socketpair(int, int, int, int*) 288,-1