fix evaluation behavior mismatch between functions and lambdas
Signed-off-by: Ava Hahn <ava@sunnypup.io>
This commit is contained in:
parent
e0b837cb21
commit
398726568a
4 changed files with 41 additions and 13 deletions
|
|
@ -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)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue