patches/strace/4.5.17/120-fix-arm-bad-syscall.patch
changeset 974 e298ce9ba8fe
parent 747 d3e603e7c17c
     1.1 --- /dev/null	Thu Jan 01 00:00:00 1970 +0000
     1.2 +++ b/patches/strace/4.5.17/120-fix-arm-bad-syscall.patch	Sat Oct 25 15:44:05 2008 +0000
     1.3 @@ -0,0 +1,23 @@
     1.4 +Original patch from gentoo: ../../dev/crosstool-NG/ct-ng.trunk/patches/strace/4.5.17/120-fix-arm-bad-syscall.patch
     1.5 +-= BEGIN original header =-
     1.6 +diff -dur strace-4.5.16.orig/syscall.c strace-4.5.16/syscall.c
     1.7 +-= END original header =-
     1.8 +diff -durN strace-4.5.17.orig/syscall.c strace-4.5.17/syscall.c
     1.9 +--- strace-4.5.17.orig/syscall.c	2008-05-28 01:18:29.000000000 +0200
    1.10 ++++ strace-4.5.17/syscall.c	2008-10-24 21:30:13.000000000 +0200
    1.11 +@@ -1016,6 +1016,15 @@
    1.12 + 		/*
    1.13 + 		 * Note: we only deal with only 32-bit CPUs here.
    1.14 + 		 */
    1.15 ++
    1.16 ++		if (!(tcp->flags & TCB_INSYSCALL) &&
    1.17 ++		    (tcp->flags & TCB_WAITEXECVE)) {
    1.18 ++			/* caught a fake syscall from the execve's exit */
    1.19 ++			tcp->flags &= ~TCB_WAITEXECVE;
    1.20 ++			return 0;
    1.21 ++		}
    1.22 ++
    1.23 ++
    1.24 + 		if (regs.ARM_cpsr & 0x20) {
    1.25 + 			/*
    1.26 + 			 * Get the Thumb-mode system call number