diff options
| -rw-r--r-- | vm/bhyve/bhyve.go | 2 | ||||
| -rw-r--r-- | vm/gce/gce.go | 4 | ||||
| -rw-r--r-- | vm/vmimpl/freebsd.go | 4 | ||||
| -rw-r--r-- | vm/vmimpl/openbsd.go | 4 | ||||
| -rw-r--r-- | vm/vmm/vmm.go | 2 |
5 files changed, 8 insertions, 8 deletions
diff --git a/vm/bhyve/bhyve.go b/vm/bhyve/bhyve.go index 0000e2c27..810ad4241 100644 --- a/vm/bhyve/bhyve.go +++ b/vm/bhyve/bhyve.go @@ -346,7 +346,7 @@ func (inst *instance) Run(timeout time.Duration, stop <-chan bool, command strin } func (inst *instance) Diagnose() ([]byte, bool) { - return nil, vmimpl.DiagnoseFreeBSD(inst.consolew) + return vmimpl.DiagnoseFreeBSD(inst.consolew) } func parseIP(output []byte) string { diff --git a/vm/gce/gce.go b/vm/gce/gce.go index 98ab494dd..097bcd707 100644 --- a/vm/gce/gce.go +++ b/vm/gce/gce.go @@ -371,10 +371,10 @@ func waitForConsoleConnect(merger *vmimpl.OutputMerger) error { func (inst *instance) Diagnose() ([]byte, bool) { if inst.env.OS == "freebsd" { - return nil, vmimpl.DiagnoseFreeBSD(inst.consolew) + return vmimpl.DiagnoseFreeBSD(inst.consolew) } if inst.env.OS == "openbsd" { - return nil, vmimpl.DiagnoseOpenBSD(inst.consolew) + return vmimpl.DiagnoseOpenBSD(inst.consolew) } return nil, false } diff --git a/vm/vmimpl/freebsd.go b/vm/vmimpl/freebsd.go index c6074028a..f2ebfba56 100644 --- a/vm/vmimpl/freebsd.go +++ b/vm/vmimpl/freebsd.go @@ -12,7 +12,7 @@ import ( // is expected to be connected to a panicked FreeBSD kernel. If kernel // just hanged, we've lost connection or detected some non-panic // error, console still shows normal login prompt. -func DiagnoseFreeBSD(w io.Writer) bool { +func DiagnoseFreeBSD(w io.Writer) ([]byte, bool) { commands := []string{ "", "set $lines = 0", // disable pagination @@ -28,5 +28,5 @@ func DiagnoseFreeBSD(w io.Writer) bool { w.Write([]byte(c + "\n")) time.Sleep(1 * time.Second) } - return true + return nil, true } diff --git a/vm/vmimpl/openbsd.go b/vm/vmimpl/openbsd.go index 5e5ce3d3f..73460cb80 100644 --- a/vm/vmimpl/openbsd.go +++ b/vm/vmimpl/openbsd.go @@ -12,7 +12,7 @@ import ( // is expected to be connected to a paniced openbsd kernel. If kernel // just hanged, we've lost connection or detected some non-panic // error, console still shows normal login prompt. -func DiagnoseOpenBSD(w io.Writer) bool { +func DiagnoseOpenBSD(w io.Writer) ([]byte, bool) { commands := []string{ "", "set $lines = 0", // disable pagination @@ -30,5 +30,5 @@ func DiagnoseOpenBSD(w io.Writer) bool { w.Write([]byte(c + "\n")) time.Sleep(1 * time.Second) } - return true + return nil, true } diff --git a/vm/vmm/vmm.go b/vm/vmm/vmm.go index f3b5fc457..62908de1f 100644 --- a/vm/vmm/vmm.go +++ b/vm/vmm/vmm.go @@ -311,7 +311,7 @@ func (inst *instance) Run(timeout time.Duration, stop <-chan bool, command strin } func (inst *instance) Diagnose() ([]byte, bool) { - return nil, vmimpl.DiagnoseOpenBSD(inst.consolew) + return vmimpl.DiagnoseOpenBSD(inst.consolew) } // Run the given vmctl(8) command and wait for it to finish. |
