aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDoug Kwan <dougkwan@google.com>2010-07-29 13:04:29 -0700
committerDoug Kwan <dougkwan@google.com>2010-07-29 13:04:29 -0700
commitcfa96b379cdd6561a5cc89f2bb86ee9f4b2a3928 (patch)
tree939cabf7dba44c5f551c55fb9937ae4376eca901
parentfb19d317e61dfbb8234bb23d5c7cc40827667ec2 (diff)
downloadstrace-gingerbread-release.tar.gz
2007-11-01 Roland McGrath <roland@redhat.com> * syscall.c (get_scno) [ARM]: Check TCB_WAITEXECVE. Reported by Bernhard Fischer <rep.dot.nop@gmail.com>. Change-Id: Iba2a50fc1104bfe899163e975cf94745d72b4db6 http://strace.git.sourceforge.net/git/gitweb.cgi?p=strace/strace;a=commitdiff;h=9bc6340d21cb20d2c775863598068c1a29460eba
-rw-r--r--syscall.c8
1 files changed, 8 insertions, 0 deletions
diff --git a/syscall.c b/syscall.c
index 0958e1bb..fa9c4546 100644
--- a/syscall.c
+++ b/syscall.c
@@ -1013,6 +1013,14 @@ struct tcb *tcp;
* We only need to grab the syscall number on syscall entry.
*/
if (regs.ARM_ip == 0) {
+ if (!(tcp->flags & TCB_INSYSCALL)) {
+ /* Check if we return from execve. */
+ if (tcp->flags & TCB_WAITEXECVE) {
+ tcp->flags &= ~TCB_WAITEXECVE;
+ return 0;
+ }
+ }
+
/*
* Note: we only deal with only 32-bit CPUs here.
*/