mirror of
https://github.com/reactos/syzkaller.git
synced 2025-02-25 14:11:14 +00:00
dump executor output directly to console when debug
Otherwise there is no way to see the output if executor hangs dead.
This commit is contained in:
parent
505473bd9b
commit
a8c682fe99
@ -194,8 +194,13 @@ func (env *Env) execBin() (output, strace []byte, failed, hanged bool, err0 erro
|
||||
cmd.ExtraFiles = append(cmd.ExtraFiles, env.inFile, env.outFile)
|
||||
cmd.Env = []string{}
|
||||
cmd.Dir = dir
|
||||
cmd.Stdout = wp
|
||||
cmd.Stderr = wp
|
||||
if env.flags&FlagDebug == 0 {
|
||||
cmd.Stdout = wp
|
||||
cmd.Stderr = wp
|
||||
} else {
|
||||
cmd.Stdout = os.Stdout
|
||||
cmd.Stderr = os.Stdout
|
||||
}
|
||||
if syscall.Getuid() == 0 {
|
||||
// Running under root, more isolation is possible.
|
||||
cmd.SysProcAttr = &syscall.SysProcAttr{Setpgid: true, Cloneflags: syscall.CLONE_NEWNS}
|
||||
|
Loading…
x
Reference in New Issue
Block a user