summaryrefslogtreecommitdiff
path: root/strace.c
diff options
context:
space:
mode:
authorDmitry V. Levin <ldv@altlinux.org>2013-05-14 22:35:46 +0000
committerDmitry V. Levin <ldv@altlinux.org>2013-05-14 22:50:11 +0000
commit1d2435b20bc81fb52c3edb19a3b6247ce2d43ca6 (patch)
treee875e816f3c8d19bc68020328373092c3f8c06ba /strace.c
parent882478a0724c04287ac232c212312c8e094cce43 (diff)
downloadstrace-1d2435b20bc81fb52c3edb19a3b6247ce2d43ca6.tar.gz
strace-1d2435b20bc81fb52c3edb19a3b6247ce2d43ca6.tar.bz2
strace-1d2435b20bc81fb52c3edb19a3b6247ce2d43ca6.tar.xz
NOMMU: do not hide startup syscalls unless in -D mode
On NOMMU systems in "strace PROG" case, we have no way to attach to the tracee before it calls execve unless in -D mode. That is, the first execve call is very likely to be missed, and setting hide_log_until_execve just results to empty log. * strace.c (init) [NOMMU_SYSTEM]: Do not set hide_log_until_execve unless in -D mode.
Diffstat (limited to 'strace.c')
-rw-r--r--strace.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/strace.c b/strace.c
index 7c85123..5b7fbc2 100644
--- a/strace.c
+++ b/strace.c
@@ -1797,7 +1797,8 @@ init(int argc, char *argv[])
* in the startup_child() mode we kill the spawned process anyway.
*/
if (argv[0]) {
- hide_log_until_execve = 1;
+ if (!NOMMU_SYSTEM || daemonized_tracer)
+ hide_log_until_execve = 1;
skip_one_b_execve = 1;
startup_child(argv);
}