From 1b9408864f7f575b83b8f822e7551772ccd37009 Mon Sep 17 00:00:00 2001 From: Ophestra Date: Mon, 17 Mar 2025 22:36:39 +0900 Subject: sandbox: pass cmd to cancel function This is not usually in scope otherwise. Signed-off-by: Ophestra --- sandbox/init.go | 3 +++ 1 file changed, 3 insertions(+) (limited to 'sandbox/init.go') diff --git a/sandbox/init.go b/sandbox/init.go index 5ebac810..05d66236 100644 --- a/sandbox/init.go +++ b/sandbox/init.go @@ -312,10 +312,13 @@ func Init(prepare func(prefix string), setVerbose func(verbose bool)) { switch { case w.wstatus.Exited(): r = w.wstatus.ExitStatus() + msg.Verbosef("initial process exited with code %d", w.wstatus.ExitStatus()) case w.wstatus.Signaled(): r = 128 + int(w.wstatus.Signal()) + msg.Verbosef("initial process exited with signal %s", w.wstatus.Signal()) default: r = 255 + msg.Verbosef("initial process exited with status %#x", w.wstatus) } go func() { -- cgit v1.3.1