From e0e04814b40f1d4077d1cf6001395bd6a919b288 Mon Sep 17 00:00:00 2001 From: Fabricio Voznika Date: Tue, 9 Mar 2021 20:10:16 -0800 Subject: Fix invalid interface conversion in runner panic: interface conversion: interface {} is syscall.WaitStatus, not unix.WaitStatus goroutine 1 [running]: main.runTestCaseNative(0xc0001fc000, 0xe3, 0xc000119b60, 0x1, 0x1, 0x0, 0x0) test/runner/runner.go:185 +0xa94 main.main() test/runner/runner.go:118 +0x745 PiperOrigin-RevId: 361957796 --- runsc/specutils/namespace.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'runsc') diff --git a/runsc/specutils/namespace.go b/runsc/specutils/namespace.go index d8b9334c7..69d7ba5c4 100644 --- a/runsc/specutils/namespace.go +++ b/runsc/specutils/namespace.go @@ -275,7 +275,7 @@ func MaybeRunAsRoot() error { }() if err := cmd.Wait(); err != nil { if exit, ok := err.(*exec.ExitError); ok { - if ws, ok := exit.Sys().(unix.WaitStatus); ok { + if ws, ok := exit.Sys().(syscall.WaitStatus); ok { os.Exit(ws.ExitStatus()) } log.Warningf("No wait status provided, exiting with -1: %v", err) -- cgit v1.2.3