fmsg: support temporarily withholding output

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:
2024-10-26 23:09:32 +09:00
parent 093e99d062
commit ae1a102882
11 changed files with 105 additions and 32 deletions

View File

@@ -109,7 +109,7 @@ func (s *Std) Open(name string) (fs.File, error) {
return os.Open(name)
}
func (s *Std) Exit(code int) {
os.Exit(code)
fmsg.Exit(code)
}
const xdgRuntimeDir = "XDG_RUNTIME_DIR"