mirror of
https://github.com/fish-shell/fish-shell
synced 2025-01-04 00:58:46 +00:00
Only donate term if we're interactive *and* have the terminal
As it turns out otherwise fish would hang when sddm starts it as the login shell.
Belongs to #7842.
(cherry picked from commit 7f7cfcf339
)
This commit is contained in:
parent
e31096d7ed
commit
92c28291df
1 changed files with 2 additions and 1 deletions
|
@ -1342,7 +1342,8 @@ void reader_init() {
|
||||||
|
|
||||||
// Set up our fixed terminal modes once,
|
// Set up our fixed terminal modes once,
|
||||||
// so we don't get flow control just because we inherited it.
|
// so we don't get flow control just because we inherited it.
|
||||||
if (is_interactive_session()) {
|
if (is_interactive_session() &&
|
||||||
|
getpgrp() == tcgetpgrp(STDIN_FILENO)) {
|
||||||
term_donate(/* quiet */ true);
|
term_donate(/* quiet */ true);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue