fmsg: support temporarily withholding output
All checks were successful
test / test (push) Successful in 31s
All checks were successful
test / test (push) Successful in 31s
Trying to print to a shared stdout is a terrible idea. This change makes it possible to withhold output for the lifetime of the sandbox. Signed-off-by: Ophestra Umiker <cat@ophivana.moe>
This commit is contained in:
@@ -129,7 +129,7 @@ func doInit(fd uintptr) {
|
||||
select {
|
||||
case s := <-sig:
|
||||
fmsg.VPrintln("received", s.String())
|
||||
os.Exit(0)
|
||||
fmsg.Exit(0)
|
||||
case w := <-info:
|
||||
if w.wpid == cmd.Process.Pid {
|
||||
switch {
|
||||
@@ -147,10 +147,10 @@ func doInit(fd uintptr) {
|
||||
}()
|
||||
}
|
||||
case <-done:
|
||||
os.Exit(r)
|
||||
fmsg.Exit(r)
|
||||
case <-timeout:
|
||||
fmsg.Println("timeout exceeded waiting for lingering processes")
|
||||
os.Exit(r)
|
||||
fmsg.Exit(r)
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user