aboutsummaryrefslogtreecommitdiffstats
path: root/vm/starnix
diff options
context:
space:
mode:
authorLaura Peskin <pesk@google.com>2023-10-23 21:18:47 -0700
committerDmitry Vyukov <dvyukov@google.com>2024-06-18 09:36:15 +0000
commite770cc218473a1722d5920c92a0e642c4c0c9128 (patch)
treeaa7448044b0da1b083bb03f754b70050e50c0220 /vm/starnix
parent58711dfa434f653312bd9a7f87cd466609bd02d4 (diff)
vm/starnix: `-debug` sends kernel and syzkaller logs to stdout
Now these logs go to stdout when syz-manager runs with the `-debug` flag.
Diffstat (limited to 'vm/starnix')
-rw-r--r--vm/starnix/starnix.go6
1 files changed, 5 insertions, 1 deletions
diff --git a/vm/starnix/starnix.go b/vm/starnix/starnix.go
index 657d173e9..7d52c6c61 100644
--- a/vm/starnix/starnix.go
+++ b/vm/starnix/starnix.go
@@ -137,7 +137,11 @@ func (pool *Pool) Create(workdir string, index int) (vmimpl.Instance, error) {
func (inst *instance) boot() error {
inst.port = vmimpl.UnusedTCPPort()
// Start output merger.
- inst.merger = vmimpl.NewOutputMerger(nil)
+ var tee io.Writer
+ if inst.debug {
+ tee = os.Stdout
+ }
+ inst.merger = vmimpl.NewOutputMerger(tee)
inst.ffx("doctor", "--restart-daemon")