aboutsummaryrefslogtreecommitdiffhomepage
path: root/reader.cpp
diff options
context:
space:
mode:
authorGravatar ridiculousfish <corydoras@ridiculousfish.com>2012-07-15 12:46:40 -0700
committerGravatar ridiculousfish <corydoras@ridiculousfish.com>2012-07-15 12:46:40 -0700
commit4755c5f8c892978919d9b652bcfee6ef220c7ca6 (patch)
tree2733493e636c607de92f304ec45f717fac89ee78 /reader.cpp
parentea1bfd715e0765db680f804d2450d44e4028a519 (diff)
Deliver SIGHUP when we're exiting, even if stdin is not closed.
Diffstat (limited to 'reader.cpp')
-rw-r--r--reader.cpp6
1 files changed, 5 insertions, 1 deletions
diff --git a/reader.cpp b/reader.cpp
index af3cdf0d..5c295539 100644
--- a/reader.cpp
+++ b/reader.cpp
@@ -2358,7 +2358,11 @@ static void handle_end_loop()
}
else
{
- if( !isatty(0) )
+ /* PCA: we used to only hangup jobs if stdin was closed. This prevented child processes from exiting. It's unclear to my why it matters if stdin is closed, but it seems to me if we're forcing an exit, we definitely want to hang up our processes.
+
+ See https://github.com/fish-shell/fish-shell/issues/138
+ */
+ if( reader_exit_forced() || !isatty(0) )
{
/*
We already know that stdin is a tty since we're