summaryrefslogtreecommitdiffstats
path: root/ipc
diff options
context:
space:
mode:
authorJustus Winter <justus@sequoia-pgp.org>2019-10-21 11:00:22 +0200
committerJustus Winter <justus@sequoia-pgp.org>2019-10-21 11:00:22 +0200
commitcb497bd7d74df0c85976ae2ed8c8afccb5070f6e (patch)
treef6f09047c00f523f4f3dd419435de6b552512928 /ipc
parent047bd383bb846ca05b10b0dbc3eef905527e67e8 (diff)
ipc: Close stdin and stderr of daemonized processes.
- Rust's std::process::Command::output waits for the streams to close.
Diffstat (limited to 'ipc')
-rw-r--r--ipc/src/lib.rs2
1 files changed, 2 insertions, 0 deletions
diff --git a/ipc/src/lib.rs b/ipc/src/lib.rs
index c4df9311..cde5c3c3 100644
--- a/ipc/src/lib.rs
+++ b/ipc/src/lib.rs
@@ -275,6 +275,8 @@ impl Descriptor {
.arg(format!("{}", self.ctx.ephemeral()))
// l will be closed here if the exec fails.
.stdin(unsafe { Stdio::from_raw_fd(fd) })
+ .stdout(Stdio::null())
+ .stderr(Stdio::null())
.spawn()?;
Ok(())
}