Zsh Mailing List Archive
Messages sorted by:
Reverse Date,
Date,
Thread,
Author
Re: GNU nohup oddness
- X-seq: zsh-workers 17989
- From: "Bart Schaefer" <schaefer@xxxxxxxxxxxxxxxx>
- To: zsh-workers@xxxxxxxxxx
- Subject: Re: GNU nohup oddness
- Date: Sat, 7 Dec 2002 17:43:23 +0000
- Cc: 171716@xxxxxxxxxxxxxxx, phil@xxxxxxxx
- In-reply-to: <20021207152412.GA15901@xxxxxxxx>
- Mailing-list: contact zsh-workers-help@xxxxxxxxxx; run by ezmlm
- References: <20021206003013.GA10400@xxxxxxxx> <1021206101446.ZM10013@xxxxxxxxxxxxxxxxxxxxxxx> <20021207152412.GA15901@xxxxxxxx>
On Dec 7, 10:24am, Clint Adams wrote:
} Subject: Re: GNU nohup oddness
}
} > (3) In Src/init.c:init_signals(), zsh explicitly installs a SIGHUP
} > handler, even in non-interactive shells. It has done so for a
} > very long time -- as far back as recorded in my CVS of 3.0.x,
} > which means prior to 27-Jun-97.
}
} So is this the right thing to do?
[Patch moves install_handler(SIGHUP) call to `if (interact)' block]
I'm not certain. Probably more correct would be something like:
@@ -870,7 +897,8 @@
signal_ignore(SIGQUIT);
#endif
- install_handler(SIGHUP);
+ if (signal_ignore(SIGHUP) != SIG_IGN)
+ install_handler(SIGHUP);
install_handler(SIGCHLD);
#ifdef SIGWINCH
install_handler(SIGWINCH);
Or maybe even:
@@ -870,7 +897,10 @@
signal_ignore(SIGQUIT);
#endif
- install_handler(SIGHUP);
+ if (signal_ignore(SIGHUP) == SIG_IGN)
+ opts[HUP] = 0;
+ else
+ install_handler(SIGHUP);
install_handler(SIGCHLD);
#ifdef SIGWINCH
install_handler(SIGWINCH);
Does anybody else have an opinion?
--
Bart Schaefer Brass Lantern Enterprises
http://www.well.com/user/barts http://www.brasslantern.com
Zsh: http://www.zsh.org | PHPerl Project: http://phperl.sourceforge.net
Messages sorted by:
Reverse Date,
Date,
Thread,
Author