fix evaluation behavior mismatch between functions and lambdas

Signed-off-by: Ava Hahn <ava@sunnypup.io>
This commit is contained in:
Ava Apples Affine 2023-06-08 12:48:34 -07:00
parent e0b837cb21
commit 398726568a
4 changed files with 41 additions and 13 deletions

View file

@ -198,12 +198,10 @@ fn launch_command(
// glibc says to do this in both parent and child
if let Ok(child) = newchld {
let pid = child.id();
if let Err(e) = unistd::setpgid(
_ = unistd::setpgid(
Pid::from_raw(pid as i32),
Pid::from_raw(pid as i32),
) {
eprintln!("parent couldnt setpgid on chld: {}", e);
}
); // ignore result
state.children.push(child);
if !background {
make_foreground(pid, state)