Fix follow fork/vfork on Linux ARM OABI

__NR_SYSCALL_BASE eis 0 for EABI and is 0x900000 for OABI.
* process (change_syscall) [LINUX && ARM]: Mask off the high order bits
when changing syscall.

Signed-off-by: Steve Bennett <steveb@workware.net.au>
Reviewed-by: Kirill A. Shutemov <kirill@shutemov.name>
This commit is contained in:
Дмитрий Левин 2009-09-18 11:30:14 +00:00
parent 86b23b73b8
commit 7674006eed

View File

@ -792,7 +792,7 @@ change_syscall(struct tcb *tcp, int new)
# define PTRACE_SET_SYSCALL 23
# endif
if (ptrace (PTRACE_SET_SYSCALL, tcp->pid, 0, new) != 0)
if (ptrace (PTRACE_SET_SYSCALL, tcp->pid, 0, new & 0xffff) != 0)
return -1;
return 0;