fix needless pg churn
This commit is contained in:
parent
a3181aa210
commit
014be6ece3
1 changed files with 5 additions and 6 deletions
|
|
@ -471,12 +471,11 @@ pub fn load_posix_shell(syms: &mut SymTable, shell_state: Rc<RefCell<ShellState>
|
|||
).expect("couldn't take terminal from owning process")
|
||||
}
|
||||
|
||||
if let Err(e) = unistd::setpgid(
|
||||
unistd::Pid::from_raw(0),
|
||||
unistd::Pid::from_raw(0)
|
||||
) {
|
||||
panic!("couldn't set PGID: {}", e)
|
||||
};
|
||||
if pid != pgid {
|
||||
if let Err(e) = unistd::setpgid(pid, pid) {
|
||||
panic!("couldn't set PGID: {}", e)
|
||||
};
|
||||
}
|
||||
|
||||
if let Err(e) = unistd::tcsetpgrp(0, pid) {
|
||||
panic!("couldn't grab terminal: {}", e)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue